home *** CD-ROM | disk | FTP | other *** search
/ BBS in a Box 5 / BBS in a Box -Volume V (BBS in a Box) (April 1992).iso / Files / Prog / M / MPWGCC (Docs).cpt / Documents / Info / gcc.info-7 < prev    next >
MacBinary  |  1990-03-14  |  45.4 KB  |  [TEXT/MPS ]

open in: MacOS 8.1     |     Win98     |     DOS

browse contents    |     view JSON data     |     view as text


This file was processed as: MacBinary (archive/macBinary).

ConfidenceProgramDetectionMatch TypeSupport
10% dexvert MacBinary (archive/macBinary) fallback Supported
1% dexvert Text File (text/txt) fallback Supported
100% file MacBinary II, Wed Mar 14 10:20:39 1990, modified Wed Mar 14 10:20:39 1990, creator 'MPS ', type ASCII, 45937 bytes "gcc.info-7" , at 0xb3f1 382 bytes resource default (weak)
99% file data default
74% TrID Macintosh plain text (MacBinary) default
25% TrID MacBinary 2 default (weak)
100% siegfried fmt/1762 MacBinary (II) default
100% lsar MacBinary default


id metadata
keyvalue
macFileType[TEXT]
macFileCreator[MPS ]



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 00 0a 67 63 63 2e 69 6e | 66 6f 2d 37 00 00 00 00 |..gcc.in|fo-7....|
|00000010| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000040| 00 54 45 58 54 4d 50 53 | 20 00 00 00 00 00 00 00 |.TEXTMPS| .......|
|00000050| 00 00 00 00 00 b3 71 00 | 00 01 7e a2 24 11 c7 a2 |......q.|..~.$...|
|00000060| 24 11 c7 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |$.......|........|
|00000070| 00 00 00 00 00 00 00 00 | 00 00 81 81 cc 17 00 00 |........|........|
|00000080| 49 6e 66 6f 20 66 69 6c | 65 20 67 63 63 2e 69 6e |Info fil|e gcc.in|
|00000090| 66 6f 2c 20 70 72 6f 64 | 75 63 65 64 20 62 79 20 |fo, prod|uced by |
|000000a0| 4d 61 6b 65 69 6e 66 6f | 2c 20 2d 2a 2d 20 54 65 |Makeinfo|, -*- Te|
|000000b0| 78 74 20 2d 2a 2d 20 66 | 72 6f 6d 20 69 6e 70 75 |xt -*- f|rom inpu|
|000000c0| 74 0d 66 69 6c 65 20 67 | 63 63 2e 74 65 78 69 6e |t.file g|cc.texin|
|000000d0| 66 6f 2e 0d 0d 54 68 69 | 73 20 66 69 6c 65 20 64 |fo...Thi|s file d|
|000000e0| 6f 63 75 6d 65 6e 74 73 | 20 74 68 65 20 75 73 65 |ocuments| the use|
|000000f0| 20 61 6e 64 20 74 68 65 | 20 69 6e 74 65 72 6e 61 | and the| interna|
|00000100| 6c 73 20 6f 66 20 74 68 | 65 20 47 4e 55 20 63 6f |ls of th|e GNU co|
|00000110| 6d 70 69 6c 65 72 2e 0d | 0d 43 6f 70 79 72 69 67 |mpiler..|.Copyrig|
|00000120| 68 74 20 28 43 29 20 31 | 39 38 38 2c 20 31 39 38 |ht (C) 1|988, 198|
|00000130| 39 20 46 72 65 65 20 53 | 6f 66 74 77 61 72 65 20 |9 Free S|oftware |
|00000140| 46 6f 75 6e 64 61 74 69 | 6f 6e 2c 20 49 6e 63 2e |Foundati|on, Inc.|
|00000150| 0d 0d 50 65 72 6d 69 73 | 73 69 6f 6e 20 69 73 20 |..Permis|sion is |
|00000160| 67 72 61 6e 74 65 64 20 | 74 6f 20 6d 61 6b 65 20 |granted |to make |
|00000170| 61 6e 64 20 64 69 73 74 | 72 69 62 75 74 65 20 76 |and dist|ribute v|
|00000180| 65 72 62 61 74 69 6d 20 | 63 6f 70 69 65 73 20 6f |erbatim |copies o|
|00000190| 66 20 74 68 69 73 0d 6d | 61 6e 75 61 6c 20 70 72 |f this.m|anual pr|
|000001a0| 6f 76 69 64 65 64 20 74 | 68 65 20 63 6f 70 79 72 |ovided t|he copyr|
|000001b0| 69 67 68 74 20 6e 6f 74 | 69 63 65 20 61 6e 64 20 |ight not|ice and |
|000001c0| 74 68 69 73 20 70 65 72 | 6d 69 73 73 69 6f 6e 20 |this per|mission |
|000001d0| 6e 6f 74 69 63 65 20 61 | 72 65 0d 70 72 65 73 65 |notice a|re.prese|
|000001e0| 72 76 65 64 20 6f 6e 20 | 61 6c 6c 20 63 6f 70 69 |rved on |all copi|
|000001f0| 65 73 2e 0d 0d 50 65 72 | 6d 69 73 73 69 6f 6e 20 |es...Per|mission |
|00000200| 69 73 20 67 72 61 6e 74 | 65 64 20 74 6f 20 63 6f |is grant|ed to co|
|00000210| 70 79 20 61 6e 64 20 64 | 69 73 74 72 69 62 75 74 |py and d|istribut|
|00000220| 65 20 6d 6f 64 69 66 69 | 65 64 20 76 65 72 73 69 |e modifi|ed versi|
|00000230| 6f 6e 73 20 6f 66 0d 74 | 68 69 73 20 6d 61 6e 75 |ons of.t|his manu|
|00000240| 61 6c 20 75 6e 64 65 72 | 20 74 68 65 20 63 6f 6e |al under| the con|
|00000250| 64 69 74 69 6f 6e 73 20 | 66 6f 72 20 76 65 72 62 |ditions |for verb|
|00000260| 61 74 69 6d 20 63 6f 70 | 79 69 6e 67 2c 20 70 72 |atim cop|ying, pr|
|00000270| 6f 76 69 64 65 64 20 61 | 6c 73 6f 0d 74 68 61 74 |ovided a|lso.that|
|00000280| 20 74 68 65 20 73 65 63 | 74 69 6f 6e 73 20 65 6e | the sec|tions en|
|00000290| 74 69 74 6c 65 64 20 60 | 60 47 4e 55 20 47 65 6e |titled `|`GNU Gen|
|000002a0| 65 72 61 6c 20 50 75 62 | 6c 69 63 20 4c 69 63 65 |eral Pub|lic Lice|
|000002b0| 6e 73 65 27 27 20 61 6e | 64 0d 60 60 50 72 6f 74 |nse'' an|d.``Prot|
|000002c0| 65 63 74 20 59 6f 75 72 | 20 46 72 65 65 64 6f 6d |ect Your| Freedom|
|000002d0| 2d 2d 46 69 67 68 74 20 | 60 4c 6f 6f 6b 20 41 6e |--Fight |`Look An|
|000002e0| 64 20 46 65 65 6c 27 27 | 27 20 61 72 65 20 69 6e |d Feel''|' are in|
|000002f0| 63 6c 75 64 65 64 20 65 | 78 61 63 74 6c 79 0d 61 |cluded e|xactly.a|
|00000300| 73 20 69 6e 20 74 68 65 | 20 6f 72 69 67 69 6e 61 |s in the| origina|
|00000310| 6c 2c 20 61 6e 64 20 70 | 72 6f 76 69 64 65 64 20 |l, and p|rovided |
|00000320| 74 68 61 74 20 74 68 65 | 20 65 6e 74 69 72 65 20 |that the| entire |
|00000330| 72 65 73 75 6c 74 69 6e | 67 20 64 65 72 69 76 65 |resultin|g derive|
|00000340| 64 0d 77 6f 72 6b 20 69 | 73 20 64 69 73 74 72 69 |d.work i|s distri|
|00000350| 62 75 74 65 64 20 75 6e | 64 65 72 20 74 68 65 20 |buted un|der the |
|00000360| 74 65 72 6d 73 20 6f 66 | 20 61 20 70 65 72 6d 69 |terms of| a permi|
|00000370| 73 73 69 6f 6e 20 6e 6f | 74 69 63 65 20 69 64 65 |ssion no|tice ide|
|00000380| 6e 74 69 63 61 6c 0d 74 | 6f 20 74 68 69 73 20 6f |ntical.t|o this o|
|00000390| 6e 65 2e 0d 0d 50 65 72 | 6d 69 73 73 69 6f 6e 20 |ne...Per|mission |
|000003a0| 69 73 20 67 72 61 6e 74 | 65 64 20 74 6f 20 63 6f |is grant|ed to co|
|000003b0| 70 79 20 61 6e 64 20 64 | 69 73 74 72 69 62 75 74 |py and d|istribut|
|000003c0| 65 20 74 72 61 6e 73 6c | 61 74 69 6f 6e 73 20 6f |e transl|ations o|
|000003d0| 66 20 74 68 69 73 0d 6d | 61 6e 75 61 6c 20 69 6e |f this.m|anual in|
|000003e0| 74 6f 20 61 6e 6f 74 68 | 65 72 20 6c 61 6e 67 75 |to anoth|er langu|
|000003f0| 61 67 65 2c 20 75 6e 64 | 65 72 20 74 68 65 20 61 |age, und|er the a|
|00000400| 62 6f 76 65 20 63 6f 6e | 64 69 74 69 6f 6e 73 20 |bove con|ditions |
|00000410| 66 6f 72 20 6d 6f 64 69 | 66 69 65 64 0d 76 65 72 |for modi|fied.ver|
|00000420| 73 69 6f 6e 73 2c 20 65 | 78 63 65 70 74 20 74 68 |sions, e|xcept th|
|00000430| 61 74 20 74 68 65 20 73 | 65 63 74 69 6f 6e 73 20 |at the s|ections |
|00000440| 65 6e 74 69 74 6c 65 64 | 20 60 60 47 4e 55 20 47 |entitled| ``GNU G|
|00000450| 65 6e 65 72 61 6c 20 50 | 75 62 6c 69 63 0d 4c 69 |eneral P|ublic.Li|
|00000460| 63 65 6e 73 65 27 27 20 | 61 6e 64 20 60 60 50 72 |cense'' |and ``Pr|
|00000470| 6f 74 65 63 74 20 59 6f | 75 72 20 46 72 65 65 64 |otect Yo|ur Freed|
|00000480| 6f 6d 2d 2d 46 69 67 68 | 74 20 60 4c 6f 6f 6b 20 |om--Figh|t `Look |
|00000490| 41 6e 64 20 46 65 65 6c | 27 27 27 20 61 6e 64 0d |And Feel|''' and.|
|000004a0| 74 68 69 73 20 70 65 72 | 6d 69 73 73 69 6f 6e 20 |this per|mission |
|000004b0| 6e 6f 74 69 63 65 20 6d | 61 79 20 62 65 20 69 6e |notice m|ay be in|
|000004c0| 63 6c 75 64 65 64 20 69 | 6e 20 74 72 61 6e 73 6c |cluded i|n transl|
|000004d0| 61 74 69 6f 6e 73 20 61 | 70 70 72 6f 76 65 64 20 |ations a|pproved |
|000004e0| 62 79 0d 74 68 65 20 46 | 72 65 65 20 53 6f 66 74 |by.the F|ree Soft|
|000004f0| 77 61 72 65 20 46 6f 75 | 6e 64 61 74 69 6f 6e 20 |ware Fou|ndation |
|00000500| 69 6e 73 74 65 61 64 20 | 6f 66 20 69 6e 20 74 68 |instead |of in th|
|00000510| 65 20 6f 72 69 67 69 6e | 61 6c 20 45 6e 67 6c 69 |e origin|al Engli|
|00000520| 73 68 2e 0d 0d 0d 1f 0d | 46 69 6c 65 3a 20 67 63 |sh......|File: gc|
|00000530| 63 2e 69 6e 66 6f 2c 20 | 20 4e 6f 64 65 3a 20 4f |c.info, | Node: O|
|00000540| 75 74 70 75 74 20 53 74 | 61 74 65 6d 65 6e 74 2c |utput St|atement,|
|00000550| 20 20 4e 65 78 74 3a 20 | 43 6f 6e 73 74 72 61 69 | Next: |Constrai|
|00000560| 6e 74 73 2c 20 20 50 72 | 65 76 3a 20 4f 75 74 70 |nts, Pr|ev: Outp|
|00000570| 75 74 20 54 65 6d 70 6c | 61 74 65 2c 20 20 55 70 |ut Templ|ate, Up|
|00000580| 3a 20 4d 61 63 68 69 6e | 65 20 44 65 73 63 0d 0d |: Machin|e Desc..|
|00000590| 43 20 53 74 61 74 65 6d | 65 6e 74 73 20 66 6f 72 |C Statem|ents for|
|000005a0| 20 47 65 6e 65 72 61 74 | 69 6e 67 20 41 73 73 65 | Generat|ing Asse|
|000005b0| 6d 62 6c 65 72 20 4f 75 | 74 70 75 74 0d 3d 3d 3d |mbler Ou|tput.===|
|000005c0| 3d 3d 3d 3d 3d 3d 3d 3d | 3d 3d 3d 3d 3d 3d 3d 3d |========|========|
|000005d0| 3d 3d 3d 3d 3d 3d 3d 3d | 3d 3d 3d 3d 3d 3d 3d 3d |========|========|
|000005e0| 3d 3d 3d 3d 3d 3d 3d 3d | 3d 0d 0d 4f 66 74 65 6e |========|=..Often|
|000005f0| 20 61 20 73 69 6e 67 6c | 65 20 66 69 78 65 64 20 | a singl|e fixed |
|00000600| 74 65 6d 70 6c 61 74 65 | 20 73 74 72 69 6e 67 20 |template| string |
|00000610| 63 61 6e 6e 6f 74 20 70 | 72 6f 64 75 63 65 20 63 |cannot p|roduce c|
|00000620| 6f 72 72 65 63 74 20 61 | 6e 64 0d 65 66 66 69 63 |orrect a|nd.effic|
|00000630| 69 65 6e 74 20 61 73 73 | 65 6d 62 6c 65 72 20 63 |ient ass|embler c|
|00000640| 6f 64 65 20 66 6f 72 20 | 61 6c 6c 20 74 68 65 20 |ode for |all the |
|00000650| 63 61 73 65 73 20 74 68 | 61 74 20 61 72 65 20 72 |cases th|at are r|
|00000660| 65 63 6f 67 6e 69 7a 65 | 64 20 62 79 20 61 0d 73 |ecognize|d by a.s|
|00000670| 69 6e 67 6c 65 20 69 6e | 73 74 72 75 63 74 69 6f |ingle in|structio|
|00000680| 6e 20 70 61 74 74 65 72 | 6e 2e 20 20 46 6f 72 20 |n patter|n. For |
|00000690| 65 78 61 6d 70 6c 65 2c | 20 74 68 65 20 6f 70 63 |example,| the opc|
|000006a0| 6f 64 65 73 20 6d 61 79 | 20 64 65 70 65 6e 64 20 |odes may| depend |
|000006b0| 6f 6e 0d 74 68 65 20 6b | 69 6e 64 73 20 6f 66 20 |on.the k|inds of |
|000006c0| 6f 70 65 72 61 6e 64 73 | 3b 20 6f 72 20 73 6f 6d |operands|; or som|
|000006d0| 65 20 75 6e 66 6f 72 74 | 75 6e 61 74 65 20 63 6f |e unfort|unate co|
|000006e0| 6d 62 69 6e 61 74 69 6f | 6e 73 20 6f 66 20 6f 70 |mbinatio|ns of op|
|000006f0| 65 72 61 6e 64 73 0d 6d | 61 79 20 72 65 71 75 69 |erands.m|ay requi|
|00000700| 72 65 20 65 78 74 72 61 | 20 6d 61 63 68 69 6e 65 |re extra| machine|
|00000710| 20 69 6e 73 74 72 75 63 | 74 69 6f 6e 73 2e 0d 0d | instruc|tions...|
|00000720| 49 66 20 74 68 65 20 6f | 75 74 70 75 74 20 63 6f |If the o|utput co|
|00000730| 6e 74 72 6f 6c 20 73 74 | 72 69 6e 67 20 73 74 61 |ntrol st|ring sta|
|00000740| 72 74 73 20 77 69 74 68 | 20 61 20 60 2a 27 2c 20 |rts with| a `*', |
|00000750| 74 68 65 6e 20 69 74 20 | 69 73 20 6e 6f 74 20 61 |then it |is not a|
|00000760| 6e 0d 6f 75 74 70 75 74 | 20 74 65 6d 70 6c 61 74 |n.output| templat|
|00000770| 65 20 62 75 74 20 72 61 | 74 68 65 72 20 61 20 70 |e but ra|ther a p|
|00000780| 69 65 63 65 20 6f 66 20 | 43 20 70 72 6f 67 72 61 |iece of |C progra|
|00000790| 6d 20 74 68 61 74 20 73 | 68 6f 75 6c 64 20 63 6f |m that s|hould co|
|000007a0| 6d 70 75 74 65 20 61 0d | 74 65 6d 70 6c 61 74 65 |mpute a.|template|
|000007b0| 2e 20 20 49 74 20 73 68 | 6f 75 6c 64 20 65 78 65 |. It sh|ould exe|
|000007c0| 63 75 74 65 20 61 20 60 | 72 65 74 75 72 6e 27 20 |cute a `|return' |
|000007d0| 73 74 61 74 65 6d 65 6e | 74 20 74 6f 20 72 65 74 |statemen|t to ret|
|000007e0| 75 72 6e 20 74 68 65 0d | 74 65 6d 70 6c 61 74 65 |urn the.|template|
|000007f0| 2d 73 74 72 69 6e 67 20 | 79 6f 75 20 77 61 6e 74 |-string |you want|
|00000800| 2e 20 20 4d 6f 73 74 20 | 73 75 63 68 20 74 65 6d |. Most |such tem|
|00000810| 70 6c 61 74 65 73 20 75 | 73 65 20 43 20 73 74 72 |plates u|se C str|
|00000820| 69 6e 67 20 6c 69 74 65 | 72 61 6c 73 2c 0d 77 68 |ing lite|rals,.wh|
|00000830| 69 63 68 20 72 65 71 75 | 69 72 65 20 64 6f 75 62 |ich requ|ire doub|
|00000840| 6c 65 71 75 6f 74 65 20 | 63 68 61 72 61 63 74 65 |lequote |characte|
|00000850| 72 73 20 74 6f 20 64 65 | 6c 69 6d 69 74 20 74 68 |rs to de|limit th|
|00000860| 65 6d 2e 20 20 54 6f 20 | 69 6e 63 6c 75 64 65 0d |em. To |include.|
|00000870| 74 68 65 73 65 20 64 6f | 75 62 6c 65 71 75 6f 74 |these do|ublequot|
|00000880| 65 20 63 68 61 72 61 63 | 74 65 72 73 20 69 6e 20 |e charac|ters in |
|00000890| 74 68 65 20 73 74 72 69 | 6e 67 2c 20 70 72 65 66 |the stri|ng, pref|
|000008a0| 69 78 20 65 61 63 68 20 | 6f 6e 65 20 77 69 74 68 |ix each |one with|
|000008b0| 20 60 5c 27 2e 0d 0d 54 | 68 65 20 6f 70 65 72 61 | `\'...T|he opera|
|000008c0| 6e 64 73 20 6d 61 79 20 | 62 65 20 66 6f 75 6e 64 |nds may |be found|
|000008d0| 20 69 6e 20 74 68 65 20 | 61 72 72 61 79 20 60 6f | in the |array `o|
|000008e0| 70 65 72 61 6e 64 73 27 | 2c 20 77 68 6f 73 65 20 |perands'|, whose |
|000008f0| 43 20 64 61 74 61 20 74 | 79 70 65 0d 69 73 20 60 |C data t|ype.is `|
|00000900| 72 74 78 20 5b 5d 27 2e | 0d 0d 49 74 20 69 73 20 |rtx []'.|..It is |
|00000910| 70 6f 73 73 69 62 6c 65 | 20 74 6f 20 6f 75 74 70 |possible| to outp|
|00000920| 75 74 20 61 6e 20 61 73 | 73 65 6d 62 6c 65 72 20 |ut an as|sembler |
|00000930| 69 6e 73 74 72 75 63 74 | 69 6f 6e 20 61 6e 64 20 |instruct|ion and |
|00000940| 74 68 65 6e 20 67 6f 20 | 6f 6e 20 74 6f 0d 6f 75 |then go |on to.ou|
|00000950| 74 70 75 74 20 6f 72 20 | 63 6f 6d 70 75 74 65 20 |tput or |compute |
|00000960| 6d 6f 72 65 20 6f 66 20 | 74 68 65 6d 2c 20 75 73 |more of |them, us|
|00000970| 69 6e 67 20 74 68 65 20 | 73 75 62 72 6f 75 74 69 |ing the |subrouti|
|00000980| 6e 65 0d 60 6f 75 74 70 | 75 74 5f 61 73 6d 5f 69 |ne.`outp|ut_asm_i|
|00000990| 6e 73 6e 27 2e 20 20 54 | 68 69 73 20 72 65 63 65 |nsn'. T|his rece|
|000009a0| 69 76 65 73 20 74 77 6f | 20 61 72 67 75 6d 65 6e |ives two| argumen|
|000009b0| 74 73 3a 20 61 20 74 65 | 6d 70 6c 61 74 65 2d 73 |ts: a te|mplate-s|
|000009c0| 74 72 69 6e 67 0d 61 6e | 64 20 61 20 76 65 63 74 |tring.an|d a vect|
|000009d0| 6f 72 20 6f 66 20 6f 70 | 65 72 61 6e 64 73 2e 20 |or of op|erands. |
|000009e0| 20 54 68 65 20 76 65 63 | 74 6f 72 20 6d 61 79 20 | The vec|tor may |
|000009f0| 62 65 20 60 6f 70 65 72 | 61 6e 64 73 27 2c 20 6f |be `oper|ands', o|
|00000a00| 72 20 69 74 20 6d 61 79 | 20 62 65 0d 61 6e 6f 74 |r it may| be.anot|
|00000a10| 68 65 72 20 61 72 72 61 | 79 20 6f 66 20 60 72 74 |her arra|y of `rt|
|00000a20| 78 27 20 74 68 61 74 20 | 79 6f 75 20 64 65 63 6c |x' that |you decl|
|00000a30| 61 72 65 20 6c 6f 63 61 | 6c 6c 79 20 61 6e 64 20 |are loca|lly and |
|00000a40| 69 6e 69 74 69 61 6c 69 | 7a 65 0d 79 6f 75 72 73 |initiali|ze.yours|
|00000a50| 65 6c 66 2e 0d 0d 57 68 | 65 6e 20 61 6e 20 69 6e |elf...Wh|en an in|
|00000a60| 73 6e 20 70 61 74 74 65 | 72 6e 20 68 61 73 20 6d |sn patte|rn has m|
|00000a70| 75 6c 74 69 70 6c 65 20 | 61 6c 74 65 72 6e 61 74 |ultiple |alternat|
|00000a80| 69 76 65 73 20 69 6e 20 | 69 74 73 20 63 6f 6e 73 |ives in |its cons|
|00000a90| 74 72 61 69 6e 74 73 2c | 0d 6f 66 74 65 6e 20 74 |traints,|.often t|
|00000aa0| 68 65 20 61 70 70 65 61 | 72 61 6e 63 65 20 6f 66 |he appea|rance of|
|00000ab0| 20 74 68 65 20 61 73 73 | 65 6d 62 6c 65 72 20 63 | the ass|embler c|
|00000ac0| 6f 64 65 20 69 73 20 64 | 65 74 65 72 6d 69 6e 65 |ode is d|etermine|
|00000ad0| 64 20 6d 6f 73 74 6c 79 | 20 62 79 0d 77 68 69 63 |d mostly| by.whic|
|00000ae0| 68 20 61 6c 74 65 72 6e | 61 74 69 76 65 20 77 61 |h altern|ative wa|
|00000af0| 73 20 6d 61 74 63 68 65 | 64 2e 20 20 57 68 65 6e |s matche|d. When|
|00000b00| 20 74 68 69 73 20 69 73 | 20 73 6f 2c 20 74 68 65 | this is| so, the|
|00000b10| 20 43 20 63 6f 64 65 20 | 63 61 6e 20 74 65 73 74 | C code |can test|
|00000b20| 0d 74 68 65 20 76 61 72 | 69 61 62 6c 65 20 60 77 |.the var|iable `w|
|00000b30| 68 69 63 68 5f 61 6c 74 | 65 72 6e 61 74 69 76 65 |hich_alt|ernative|
|00000b40| 27 2c 20 77 68 69 63 68 | 20 69 73 20 74 68 65 20 |', which| is the |
|00000b50| 6f 72 64 69 6e 61 6c 20 | 6e 75 6d 62 65 72 20 6f |ordinal |number o|
|00000b60| 66 20 74 68 65 0d 61 6c | 74 65 72 6e 61 74 69 76 |f the.al|ternativ|
|00000b70| 65 20 74 68 61 74 20 77 | 61 73 20 61 63 74 75 61 |e that w|as actua|
|00000b80| 6c 6c 79 20 73 61 74 69 | 73 66 69 65 64 20 28 30 |lly sati|sfied (0|
|00000b90| 20 66 6f 72 20 74 68 65 | 20 66 69 72 73 74 2c 20 | for the| first, |
|00000ba0| 31 20 66 6f 72 20 74 68 | 65 0d 73 65 63 6f 6e 64 |1 for th|e.second|
|00000bb0| 20 61 6c 74 65 72 6e 61 | 74 69 76 65 2c 20 65 74 | alterna|tive, et|
|00000bc0| 63 2e 29 2e 0d 0d 46 6f | 72 20 65 78 61 6d 70 6c |c.)...Fo|r exampl|
|00000bd0| 65 2c 20 73 75 70 70 6f | 73 65 20 74 68 65 72 65 |e, suppo|se there|
|00000be0| 20 61 72 65 20 74 77 6f | 20 6f 70 63 6f 64 65 73 | are two| opcodes|
|00000bf0| 20 66 6f 72 20 73 74 6f | 72 69 6e 67 20 7a 65 72 | for sto|ring zer|
|00000c00| 6f 2c 20 60 63 6c 72 72 | 65 67 27 0d 66 6f 72 20 |o, `clrr|eg'.for |
|00000c10| 72 65 67 69 73 74 65 72 | 73 20 61 6e 64 20 60 63 |register|s and `c|
|00000c20| 6c 72 6d 65 6d 27 20 66 | 6f 72 20 6d 65 6d 6f 72 |lrmem' f|or memor|
|00000c30| 79 20 6c 6f 63 61 74 69 | 6f 6e 73 2e 20 20 48 65 |y locati|ons. He|
|00000c40| 72 65 20 69 73 20 68 6f | 77 20 61 0d 70 61 74 74 |re is ho|w a.patt|
|00000c50| 65 72 6e 20 63 6f 75 6c | 64 20 75 73 65 20 60 77 |ern coul|d use `w|
|00000c60| 68 69 63 68 5f 61 6c 74 | 65 72 6e 61 74 69 76 65 |hich_alt|ernative|
|00000c70| 27 20 74 6f 20 63 68 6f | 6f 73 65 20 62 65 74 77 |' to cho|ose betw|
|00000c80| 65 65 6e 20 74 68 65 6d | 3a 0d 0d 20 20 20 20 20 |een them|:.. |
|00000c90| 28 64 65 66 69 6e 65 5f | 69 6e 73 6e 20 22 22 0d |(define_|insn "".|
|00000ca0| 20 20 20 20 20 20 20 5b | 28 73 65 74 20 28 6d 61 | [|(set (ma|
|00000cb0| 74 63 68 5f 6f 70 65 72 | 61 6e 64 3a 53 49 20 30 |tch_oper|and:SI 0|
|00000cc0| 20 22 67 65 6e 65 72 61 | 6c 5f 6f 70 65 72 61 6e | "genera|l_operan|
|00000cd0| 64 22 20 22 72 2c 6d 22 | 29 0d 20 20 20 20 20 20 |d" "r,m"|). |
|00000ce0| 20 20 20 20 20 20 20 28 | 63 6f 6e 73 74 5f 69 6e | (|const_in|
|00000cf0| 74 20 30 29 29 5d 0d 20 | 20 20 20 20 20 20 22 22 |t 0))]. | ""|
|00000d00| 0d 20 20 20 20 20 20 20 | 22 2a 0d 20 20 20 20 20 |. |"*. |
|00000d10| 20 20 72 65 74 75 72 6e | 20 28 77 68 69 63 68 5f | return| (which_|
|00000d20| 61 6c 74 65 72 6e 61 74 | 69 76 65 20 3d 3d 20 30 |alternat|ive == 0|
|00000d30| 0d 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 |. | |
|00000d40| 3f 20 5c 22 63 6c 72 72 | 65 67 20 25 30 5c 22 20 |? \"clrr|eg %0\" |
|00000d50| 3a 20 5c 22 63 6c 72 6d | 65 6d 20 25 30 5c 22 29 |: \"clrm|em %0\")|
|00000d60| 3b 0d 20 20 20 20 20 20 | 20 22 29 0d 0d 0d 1f 0d |;. | ").....|
|00000d70| 46 69 6c 65 3a 20 67 63 | 63 2e 69 6e 66 6f 2c 20 |File: gc|c.info, |
|00000d80| 20 4e 6f 64 65 3a 20 43 | 6f 6e 73 74 72 61 69 6e | Node: C|onstrain|
|00000d90| 74 73 2c 20 20 4e 65 78 | 74 3a 20 53 74 61 6e 64 |ts, Nex|t: Stand|
|00000da0| 61 72 64 20 4e 61 6d 65 | 73 2c 20 20 50 72 65 76 |ard Name|s, Prev|
|00000db0| 3a 20 4f 75 74 70 75 74 | 20 53 74 61 74 65 6d 65 |: Output| Stateme|
|00000dc0| 6e 74 2c 20 20 55 70 3a | 20 4d 61 63 68 69 6e 65 |nt, Up:| Machine|
|00000dd0| 20 44 65 73 63 0d 0d 4f | 70 65 72 61 6e 64 20 43 | Desc..O|perand C|
|00000de0| 6f 6e 73 74 72 61 69 6e | 74 73 0d 3d 3d 3d 3d 3d |onstrain|ts.=====|
|00000df0| 3d 3d 3d 3d 3d 3d 3d 3d | 3d 3d 3d 3d 3d 3d 0d 0d |========|======..|
|00000e00| 45 61 63 68 20 60 6d 61 | 74 63 68 5f 6f 70 65 72 |Each `ma|tch_oper|
|00000e10| 61 6e 64 27 20 69 6e 20 | 61 6e 20 69 6e 73 74 72 |and' in |an instr|
|00000e20| 75 63 74 69 6f 6e 20 70 | 61 74 74 65 72 6e 20 63 |uction p|attern c|
|00000e30| 61 6e 20 73 70 65 63 69 | 66 79 20 61 0d 63 6f 6e |an speci|fy a.con|
|00000e40| 73 74 72 61 69 6e 74 20 | 66 6f 72 20 74 68 65 20 |straint |for the |
|00000e50| 74 79 70 65 20 6f 66 20 | 6f 70 65 72 61 6e 64 73 |type of |operands|
|00000e60| 20 61 6c 6c 6f 77 65 64 | 2e 20 20 43 6f 6e 73 74 | allowed|. Const|
|00000e70| 72 61 69 6e 74 73 20 63 | 61 6e 20 73 61 79 0d 77 |raints c|an say.w|
|00000e80| 68 65 74 68 65 72 20 61 | 6e 20 6f 70 65 72 61 6e |hether a|n operan|
|00000e90| 64 20 6d 61 79 20 62 65 | 20 69 6e 20 61 20 72 65 |d may be| in a re|
|00000ea0| 67 69 73 74 65 72 2c 20 | 61 6e 64 20 77 68 69 63 |gister, |and whic|
|00000eb0| 68 20 6b 69 6e 64 73 20 | 6f 66 20 72 65 67 69 73 |h kinds |of regis|
|00000ec0| 74 65 72 3b 0d 77 68 65 | 74 68 65 72 20 74 68 65 |ter;.whe|ther the|
|00000ed0| 20 6f 70 65 72 61 6e 64 | 20 63 61 6e 20 62 65 20 | operand| can be |
|00000ee0| 61 20 6d 65 6d 6f 72 79 | 20 72 65 66 65 72 65 6e |a memory| referen|
|00000ef0| 63 65 2c 20 61 6e 64 20 | 77 68 69 63 68 20 6b 69 |ce, and |which ki|
|00000f00| 6e 64 73 20 6f 66 0d 61 | 64 64 72 65 73 73 3b 20 |nds of.a|ddress; |
|00000f10| 77 68 65 74 68 65 72 20 | 74 68 65 20 6f 70 65 72 |whether |the oper|
|00000f20| 61 6e 64 20 6d 61 79 20 | 62 65 20 61 6e 20 69 6d |and may |be an im|
|00000f30| 6d 65 64 69 61 74 65 20 | 63 6f 6e 73 74 61 6e 74 |mediate |constant|
|00000f40| 2c 20 61 6e 64 20 77 68 | 69 63 68 0d 70 6f 73 73 |, and wh|ich.poss|
|00000f50| 69 62 6c 65 20 76 61 6c | 75 65 73 20 69 74 20 6d |ible val|ues it m|
|00000f60| 61 79 20 68 61 76 65 2e | 20 20 43 6f 6e 73 74 72 |ay have.| Constr|
|00000f70| 61 69 6e 74 73 20 63 61 | 6e 20 61 6c 73 6f 20 72 |aints ca|n also r|
|00000f80| 65 71 75 69 72 65 20 74 | 77 6f 0d 6f 70 65 72 61 |equire t|wo.opera|
|00000f90| 6e 64 73 20 74 6f 20 6d | 61 74 63 68 2e 0d 0d 2a |nds to m|atch...*|
|00000fa0| 20 4d 65 6e 75 3a 0d 0d | 2a 20 53 69 6d 70 6c 65 | Menu:..|* Simple|
|00000fb0| 20 43 6f 6e 73 74 72 61 | 69 6e 74 73 3a 3a 20 20 | Constra|ints:: |
|00000fc0| 42 61 73 69 63 20 75 73 | 65 20 6f 66 20 63 6f 6e |Basic us|e of con|
|00000fd0| 73 74 72 61 69 6e 74 73 | 2e 0d 2a 20 4d 75 6c 74 |straints|..* Mult|
|00000fe0| 69 2d 41 6c 74 65 72 6e | 61 74 69 76 65 3a 3a 20 |i-Altern|ative:: |
|00000ff0| 20 20 57 68 65 6e 20 61 | 6e 20 69 6e 73 6e 20 68 | When a|n insn h|
|00001000| 61 73 20 74 77 6f 20 61 | 6c 74 65 72 6e 61 74 69 |as two a|lternati|
|00001010| 76 65 20 63 6f 6e 73 74 | 72 61 69 6e 74 2d 70 61 |ve const|raint-pa|
|00001020| 74 74 65 72 6e 73 2e 0d | 2a 20 43 6c 61 73 73 20 |tterns..|* Class |
|00001030| 50 72 65 66 65 72 65 6e | 63 65 73 3a 3a 20 20 20 |Preferen|ces:: |
|00001040| 43 6f 6e 73 74 72 61 69 | 6e 74 73 20 67 75 69 64 |Constrai|nts guid|
|00001050| 65 20 77 68 69 63 68 20 | 68 61 72 64 20 72 65 67 |e which |hard reg|
|00001060| 69 73 74 65 72 20 74 6f | 20 70 75 74 20 74 68 69 |ister to| put thi|
|00001070| 6e 67 73 20 69 6e 2e 0d | 2a 20 4d 6f 64 69 66 69 |ngs in..|* Modifi|
|00001080| 65 72 73 3a 3a 20 20 20 | 20 20 20 20 20 20 20 20 |ers:: | |
|00001090| 4d 6f 72 65 20 70 72 65 | 63 69 73 65 20 63 6f 6e |More pre|cise con|
|000010a0| 74 72 6f 6c 20 6f 76 65 | 72 20 65 66 66 65 63 74 |trol ove|r effect|
|000010b0| 73 20 6f 66 20 63 6f 6e | 73 74 72 61 69 6e 74 73 |s of con|straints|
|000010c0| 2e 0d 2a 20 4e 6f 20 43 | 6f 6e 73 74 72 61 69 6e |..* No C|onstrain|
|000010d0| 74 73 3a 3a 20 20 20 20 | 20 20 44 65 73 63 72 69 |ts:: | Descri|
|000010e0| 62 69 6e 67 20 61 20 63 | 6c 65 61 6e 20 6d 61 63 |bing a c|lean mac|
|000010f0| 68 69 6e 65 20 77 69 74 | 68 6f 75 74 20 63 6f 6e |hine wit|hout con|
|00001100| 73 74 72 61 69 6e 74 73 | 2e 0d 0d 20 0d 1f 0d 46 |straints|... ...F|
|00001110| 69 6c 65 3a 20 67 63 63 | 2e 69 6e 66 6f 2c 20 20 |ile: gcc|.info, |
|00001120| 4e 6f 64 65 3a 20 53 69 | 6d 70 6c 65 20 43 6f 6e |Node: Si|mple Con|
|00001130| 73 74 72 61 69 6e 74 73 | 2c 20 20 4e 65 78 74 3a |straints|, Next:|
|00001140| 20 4d 75 6c 74 69 2d 41 | 6c 74 65 72 6e 61 74 69 | Multi-A|lternati|
|00001150| 76 65 2c 20 20 50 72 65 | 76 3a 20 43 6f 6e 73 74 |ve, Pre|v: Const|
|00001160| 72 61 69 6e 74 73 2c 20 | 20 55 70 3a 20 43 6f 6e |raints, | Up: Con|
|00001170| 73 74 72 61 69 6e 74 73 | 0d 0d 53 69 6d 70 6c 65 |straints|..Simple|
|00001180| 20 43 6f 6e 73 74 72 61 | 69 6e 74 73 0d 2d 2d 2d | Constra|ints.---|
|00001190| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 0d |--------|-------.|
|000011a0| 0d 54 68 65 20 73 69 6d | 70 6c 65 73 74 20 6b 69 |.The sim|plest ki|
|000011b0| 6e 64 20 6f 66 20 63 6f | 6e 73 74 72 61 69 6e 74 |nd of co|nstraint|
|000011c0| 20 69 73 20 61 20 73 74 | 72 69 6e 67 20 66 75 6c | is a st|ring ful|
|000011d0| 6c 20 6f 66 20 6c 65 74 | 74 65 72 73 2c 20 65 61 |l of let|ters, ea|
|000011e0| 63 68 20 6f 66 0d 77 68 | 69 63 68 20 64 65 73 63 |ch of.wh|ich desc|
|000011f0| 72 69 62 65 73 20 6f 6e | 65 20 6b 69 6e 64 20 6f |ribes on|e kind o|
|00001200| 66 20 6f 70 65 72 61 6e | 64 20 74 68 61 74 20 69 |f operan|d that i|
|00001210| 73 20 70 65 72 6d 69 74 | 74 65 64 2e 20 20 48 65 |s permit|ted. He|
|00001220| 72 65 20 61 72 65 20 74 | 68 65 0d 6c 65 74 74 65 |re are t|he.lette|
|00001230| 72 73 20 74 68 61 74 20 | 61 72 65 20 61 6c 6c 6f |rs that |are allo|
|00001240| 77 65 64 3a 0d 0d 60 6d | 27 0d 20 20 20 20 20 41 |wed:..`m|'. A|
|00001250| 20 6d 65 6d 6f 72 79 20 | 6f 70 65 72 61 6e 64 20 | memory |operand |
|00001260| 69 73 20 61 6c 6c 6f 77 | 65 64 2c 20 77 69 74 68 |is allow|ed, with|
|00001270| 20 61 6e 79 20 6b 69 6e | 64 20 6f 66 20 61 64 64 | any kin|d of add|
|00001280| 72 65 73 73 20 74 68 61 | 74 20 74 68 65 0d 20 20 |ress tha|t the. |
|00001290| 20 20 20 6d 61 63 68 69 | 6e 65 20 73 75 70 70 6f | machi|ne suppo|
|000012a0| 72 74 73 20 69 6e 20 67 | 65 6e 65 72 61 6c 2e 0d |rts in g|eneral..|
|000012b0| 0d 60 6f 27 0d 20 20 20 | 20 20 41 20 6d 65 6d 6f |.`o'. | A memo|
|000012c0| 72 79 20 6f 70 65 72 61 | 6e 64 20 69 73 20 61 6c |ry opera|nd is al|
|000012d0| 6c 6f 77 65 64 2c 20 62 | 75 74 20 6f 6e 6c 79 20 |lowed, b|ut only |
|000012e0| 69 66 20 74 68 65 20 61 | 64 64 72 65 73 73 20 69 |if the a|ddress i|
|000012f0| 73 0d 20 20 20 20 20 22 | 6f 66 66 73 65 74 74 61 |s. "|offsetta|
|00001300| 62 6c 65 22 2e 20 20 54 | 68 69 73 20 6d 65 61 6e |ble". T|his mean|
|00001310| 73 20 74 68 61 74 20 61 | 64 64 69 6e 67 20 61 20 |s that a|dding a |
|00001320| 73 6d 61 6c 6c 20 69 6e | 74 65 67 65 72 0d 20 20 |small in|teger. |
|00001330| 20 20 20 28 61 63 74 75 | 61 6c 6c 79 2c 20 74 68 | (actu|ally, th|
|00001340| 65 20 77 69 64 74 68 20 | 69 6e 20 62 79 74 65 73 |e width |in bytes|
|00001350| 20 6f 66 20 74 68 65 20 | 6f 70 65 72 61 6e 64 2c | of the |operand,|
|00001360| 20 61 73 20 64 65 74 65 | 72 6d 69 6e 65 64 20 62 | as dete|rmined b|
|00001370| 79 0d 20 20 20 20 20 69 | 74 73 20 6d 61 63 68 69 |y. i|ts machi|
|00001380| 6e 65 20 6d 6f 64 65 29 | 20 6d 61 79 20 62 65 20 |ne mode)| may be |
|00001390| 61 64 64 65 64 20 74 6f | 20 74 68 65 20 61 64 64 |added to| the add|
|000013a0| 72 65 73 73 20 61 6e 64 | 20 74 68 65 20 72 65 73 |ress and| the res|
|000013b0| 75 6c 74 20 69 73 0d 20 | 20 20 20 20 61 6c 73 6f |ult is. | also|
|000013c0| 20 61 20 76 61 6c 69 64 | 20 6d 65 6d 6f 72 79 20 | a valid| memory |
|000013d0| 61 64 64 72 65 73 73 2e | 0d 0d 20 20 20 20 20 46 |address.|.. F|
|000013e0| 6f 72 20 65 78 61 6d 70 | 6c 65 2c 20 61 6e 20 61 |or examp|le, an a|
|000013f0| 64 64 72 65 73 73 20 77 | 68 69 63 68 20 69 73 20 |ddress w|hich is |
|00001400| 63 6f 6e 73 74 61 6e 74 | 20 69 73 20 6f 66 66 73 |constant| is offs|
|00001410| 65 74 74 61 62 6c 65 3b | 20 73 6f 20 69 73 0d 20 |ettable;| so is. |
|00001420| 20 20 20 20 61 6e 20 61 | 64 64 72 65 73 73 20 74 | an a|ddress t|
|00001430| 68 61 74 20 69 73 20 74 | 68 65 20 73 75 6d 20 6f |hat is t|he sum o|
|00001440| 66 20 61 20 72 65 67 69 | 73 74 65 72 20 61 6e 64 |f a regi|ster and|
|00001450| 20 61 20 63 6f 6e 73 74 | 61 6e 74 20 28 61 73 20 | a const|ant (as |
|00001460| 6c 6f 6e 67 0d 20 20 20 | 20 20 61 73 20 61 20 73 |long. | as a s|
|00001470| 6c 69 67 68 74 6c 79 20 | 6c 61 72 67 65 72 20 63 |lightly |larger c|
|00001480| 6f 6e 73 74 61 6e 74 20 | 69 73 20 61 6c 73 6f 20 |onstant |is also |
|00001490| 77 69 74 68 69 6e 20 74 | 68 65 20 72 61 6e 67 65 |within t|he range|
|000014a0| 20 6f 66 0d 20 20 20 20 | 20 61 64 64 72 65 73 73 | of. | address|
|000014b0| 2d 6f 66 66 73 65 74 73 | 20 73 75 70 70 6f 72 74 |-offsets| support|
|000014c0| 65 64 20 62 79 20 74 68 | 65 20 6d 61 63 68 69 6e |ed by th|e machin|
|000014d0| 65 29 3b 20 62 75 74 20 | 61 6e 20 61 75 74 6f 69 |e); but |an autoi|
|000014e0| 6e 63 72 65 6d 65 6e 74 | 0d 20 20 20 20 20 6f 72 |ncrement|. or|
|000014f0| 20 61 75 74 6f 64 65 63 | 72 65 6d 65 6e 74 20 61 | autodec|rement a|
|00001500| 64 64 72 65 73 73 20 69 | 73 20 6e 6f 74 20 6f 66 |ddress i|s not of|
|00001510| 66 73 65 74 74 61 62 6c | 65 2e 20 20 4d 6f 72 65 |fsettabl|e. More|
|00001520| 20 63 6f 6d 70 6c 69 63 | 61 74 65 64 0d 20 20 20 | complic|ated. |
|00001530| 20 20 69 6e 64 69 72 65 | 63 74 2f 69 6e 64 65 78 | indire|ct/index|
|00001540| 65 64 20 61 64 64 72 65 | 73 73 65 73 20 6d 61 79 |ed addre|sses may|
|00001550| 20 6f 72 20 6d 61 79 20 | 6e 6f 74 20 62 65 20 6f | or may |not be o|
|00001560| 66 66 73 65 74 74 61 62 | 6c 65 0d 20 20 20 20 20 |ffsettab|le. |
|00001570| 64 65 70 65 6e 64 69 6e | 67 20 6f 6e 20 74 68 65 |dependin|g on the|
|00001580| 20 6f 74 68 65 72 20 61 | 64 64 72 65 73 73 69 6e | other a|ddressin|
|00001590| 67 20 6d 6f 64 65 73 20 | 74 68 61 74 20 74 68 65 |g modes |that the|
|000015a0| 20 6d 61 63 68 69 6e 65 | 20 73 75 70 70 6f 72 74 | machine| support|
|000015b0| 73 2e 0d 0d 20 20 20 20 | 20 4e 6f 74 65 20 74 68 |s... | Note th|
|000015c0| 61 74 20 69 6e 20 61 6e | 20 6f 75 74 70 75 74 20 |at in an| output |
|000015d0| 6f 70 65 72 61 6e 64 20 | 77 68 69 63 68 20 63 61 |operand |which ca|
|000015e0| 6e 20 62 65 20 6d 61 74 | 63 68 65 64 20 62 79 20 |n be mat|ched by |
|000015f0| 61 6e 6f 74 68 65 72 0d | 20 20 20 20 20 6f 70 65 |another.| ope|
|00001600| 72 61 6e 64 2c 20 74 68 | 65 20 63 6f 6e 73 74 72 |rand, th|e constr|
|00001610| 61 69 6e 74 20 6c 65 74 | 74 65 72 20 60 6f 27 20 |aint let|ter `o' |
|00001620| 69 73 20 76 61 6c 69 64 | 20 6f 6e 6c 79 20 77 68 |is valid| only wh|
|00001630| 65 6e 0d 20 20 20 20 20 | 61 63 63 6f 6d 70 61 6e |en. |accompan|
|00001640| 69 65 64 20 62 79 20 62 | 6f 74 68 20 60 3c 27 20 |ied by b|oth `<' |
|00001650| 28 69 66 20 74 68 65 20 | 74 61 72 67 65 74 20 6d |(if the |target m|
|00001660| 61 63 68 69 6e 65 20 68 | 61 73 20 70 72 65 64 65 |achine h|as prede|
|00001670| 63 72 65 6d 65 6e 74 0d | 20 20 20 20 20 61 64 64 |crement.| add|
|00001680| 72 65 73 73 69 6e 67 29 | 20 61 6e 64 20 60 3e 27 |ressing)| and `>'|
|00001690| 20 28 69 66 20 74 68 65 | 20 74 61 72 67 65 74 20 | (if the| target |
|000016a0| 6d 61 63 68 69 6e 65 20 | 68 61 73 20 70 72 65 69 |machine |has prei|
|000016b0| 6e 63 72 65 6d 65 6e 74 | 0d 20 20 20 20 20 61 64 |ncrement|. ad|
|000016c0| 64 72 65 73 73 69 6e 67 | 29 2e 0d 0d 20 20 20 20 |dressing|)... |
|000016d0| 20 57 68 65 6e 20 74 68 | 65 20 63 6f 6e 73 74 72 | When th|e constr|
|000016e0| 61 69 6e 74 20 6c 65 74 | 74 65 72 20 60 6f 27 20 |aint let|ter `o' |
|000016f0| 69 73 20 75 73 65 64 2c | 20 74 68 65 20 72 65 6c |is used,| the rel|
|00001700| 6f 61 64 20 70 61 73 73 | 20 6d 61 79 0d 20 20 20 |oad pass| may. |
|00001710| 20 20 67 65 6e 65 72 61 | 74 65 20 69 6e 73 74 72 | genera|te instr|
|00001720| 75 63 74 69 6f 6e 73 20 | 77 68 69 63 68 20 63 6f |uctions |which co|
|00001730| 70 79 20 61 20 6e 6f 6e | 6f 66 66 73 65 74 74 61 |py a non|offsetta|
|00001740| 62 6c 65 20 61 64 64 72 | 65 73 73 20 69 6e 74 6f |ble addr|ess into|
|00001750| 0d 20 20 20 20 20 61 6e | 20 69 6e 64 65 78 20 72 |. an| index r|
|00001760| 65 67 69 73 74 65 72 2e | 20 20 54 68 65 20 69 64 |egister.| The id|
|00001770| 65 61 20 69 73 20 74 68 | 61 74 20 74 68 65 20 72 |ea is th|at the r|
|00001780| 65 67 69 73 74 65 72 20 | 63 61 6e 20 62 65 20 75 |egister |can be u|
|00001790| 73 65 64 20 61 73 0d 20 | 20 20 20 20 61 20 72 65 |sed as. | a re|
|000017a0| 70 6c 61 63 65 6d 65 6e | 74 20 6f 66 66 73 65 74 |placemen|t offset|
|000017b0| 74 61 62 6c 65 20 61 64 | 64 72 65 73 73 2e 20 20 |table ad|dress. |
|000017c0| 42 75 74 20 74 68 69 73 | 20 6d 65 74 68 6f 64 20 |But this| method |
|000017d0| 72 65 71 75 69 72 65 73 | 0d 20 20 20 20 20 74 68 |requires|. th|
|000017e0| 61 74 20 74 68 65 72 65 | 20 62 65 20 70 61 74 74 |at there| be patt|
|000017f0| 65 72 6e 73 20 74 6f 20 | 63 6f 70 79 20 61 6e 79 |erns to |copy any|
|00001800| 20 6b 69 6e 64 20 6f 66 | 20 61 64 64 72 65 73 73 | kind of| address|
|00001810| 20 69 6e 74 6f 20 61 0d | 20 20 20 20 20 72 65 67 | into a.| reg|
|00001820| 69 73 74 65 72 2e 20 20 | 41 75 74 6f 2d 69 6e 63 |ister. |Auto-inc|
|00001830| 72 65 6d 65 6e 74 20 61 | 6e 64 20 61 75 74 6f 2d |rement a|nd auto-|
|00001840| 64 65 63 72 65 6d 65 6e | 74 20 61 64 64 72 65 73 |decremen|t addres|
|00001850| 73 65 73 20 61 72 65 20 | 61 6e 0d 20 20 20 20 20 |ses are |an. |
|00001860| 65 78 63 65 70 74 69 6f | 6e 3b 20 74 68 65 72 65 |exceptio|n; there|
|00001870| 20 6e 65 65 64 20 6e 6f | 74 20 62 65 20 61 6e 20 | need no|t be an |
|00001880| 69 6e 73 74 72 75 63 74 | 69 6f 6e 20 74 68 61 74 |instruct|ion that|
|00001890| 20 63 61 6e 20 63 6f 70 | 79 20 73 75 63 68 0d 20 | can cop|y such. |
|000018a0| 20 20 20 20 61 6e 20 61 | 64 64 72 65 73 73 20 69 | an a|ddress i|
|000018b0| 6e 74 6f 20 61 20 72 65 | 67 69 73 74 65 72 2c 20 |nto a re|gister, |
|000018c0| 62 65 63 61 75 73 65 20 | 72 65 6c 6f 61 64 20 68 |because |reload h|
|000018d0| 61 6e 64 6c 65 73 20 74 | 68 65 73 65 20 63 61 73 |andles t|hese cas|
|000018e0| 65 73 0d 20 20 20 20 20 | 73 70 65 63 69 61 6c 6c |es. |speciall|
|000018f0| 79 2e 0d 0d 20 20 20 20 | 20 4d 6f 73 74 20 6f 6c |y... | Most ol|
|00001900| 64 65 72 20 6d 61 63 68 | 69 6e 65 20 64 65 73 69 |der mach|ine desi|
|00001910| 67 6e 73 20 68 61 76 65 | 20 60 60 6c 6f 61 64 20 |gns have| ``load |
|00001920| 61 64 64 72 65 73 73 27 | 27 20 69 6e 73 74 72 75 |address'|' instru|
|00001930| 63 74 69 6f 6e 73 0d 20 | 20 20 20 20 77 68 69 63 |ctions. | whic|
|00001940| 68 20 64 6f 20 6a 75 73 | 74 20 77 68 61 74 20 69 |h do jus|t what i|
|00001950| 73 20 6e 65 65 64 65 64 | 20 68 65 72 65 2e 20 20 |s needed| here. |
|00001960| 53 6f 6d 65 20 52 49 53 | 43 20 6d 61 63 68 69 6e |Some RIS|C machin|
|00001970| 65 73 20 64 6f 20 6e 6f | 74 0d 20 20 20 20 20 61 |es do no|t. a|
|00001980| 64 76 65 72 74 69 73 65 | 20 73 75 63 68 20 69 6e |dvertise| such in|
|00001990| 73 74 72 75 63 74 69 6f | 6e 73 2c 20 62 75 74 20 |structio|ns, but |
|000019a0| 74 68 65 20 70 6f 73 73 | 69 62 6c 65 20 61 64 64 |the poss|ible add|
|000019b0| 72 65 73 73 65 73 20 6f | 6e 20 74 68 65 73 65 0d |resses o|n these.|
|000019c0| 20 20 20 20 20 6d 61 63 | 68 69 6e 65 73 20 61 72 | mac|hines ar|
|000019d0| 65 20 76 65 72 79 20 6c | 69 6d 69 74 65 64 2c 20 |e very l|imited, |
|000019e0| 73 6f 20 69 74 20 69 73 | 20 65 61 73 79 20 74 6f |so it is| easy to|
|000019f0| 20 66 61 6b 65 20 74 68 | 65 6d 2e 0d 0d 60 3c 27 | fake th|em...`<'|
|00001a00| 0d 20 20 20 20 20 41 20 | 6d 65 6d 6f 72 79 20 6f |. A |memory o|
|00001a10| 70 65 72 61 6e 64 20 77 | 69 74 68 20 61 75 74 6f |perand w|ith auto|
|00001a20| 64 65 63 72 65 6d 65 6e | 74 20 61 64 64 72 65 73 |decremen|t addres|
|00001a30| 73 69 6e 67 20 28 65 69 | 74 68 65 72 0d 20 20 20 |sing (ei|ther. |
|00001a40| 20 20 70 72 65 64 65 63 | 72 65 6d 65 6e 74 20 6f | predec|rement o|
|00001a50| 72 20 70 6f 73 74 64 65 | 63 72 65 6d 65 6e 74 29 |r postde|crement)|
|00001a60| 20 69 73 20 61 6c 6c 6f | 77 65 64 2e 0d 0d 60 3e | is allo|wed...`>|
|00001a70| 27 0d 20 20 20 20 20 41 | 20 6d 65 6d 6f 72 79 20 |'. A| memory |
|00001a80| 6f 70 65 72 61 6e 64 20 | 77 69 74 68 20 61 75 74 |operand |with aut|
|00001a90| 6f 69 6e 63 72 65 6d 65 | 6e 74 20 61 64 64 72 65 |oincreme|nt addre|
|00001aa0| 73 73 69 6e 67 20 28 65 | 69 74 68 65 72 0d 20 20 |ssing (e|ither. |
|00001ab0| 20 20 20 70 72 65 69 6e | 63 72 65 6d 65 6e 74 20 | prein|crement |
|00001ac0| 6f 72 20 70 6f 73 74 69 | 6e 63 72 65 6d 65 6e 74 |or posti|ncrement|
|00001ad0| 29 20 69 73 20 61 6c 6c | 6f 77 65 64 2e 0d 0d 60 |) is all|owed...`|
|00001ae0| 72 27 0d 20 20 20 20 20 | 41 20 72 65 67 69 73 74 |r'. |A regist|
|00001af0| 65 72 20 6f 70 65 72 61 | 6e 64 20 69 73 20 61 6c |er opera|nd is al|
|00001b00| 6c 6f 77 65 64 20 70 72 | 6f 76 69 64 65 64 20 74 |lowed pr|ovided t|
|00001b10| 68 61 74 20 69 74 20 69 | 73 20 69 6e 20 61 20 67 |hat it i|s in a g|
|00001b20| 65 6e 65 72 61 6c 0d 20 | 20 20 20 20 72 65 67 69 |eneral. | regi|
|00001b30| 73 74 65 72 2e 0d 0d 60 | 64 27 2c 20 60 61 27 2c |ster...`|d', `a',|
|00001b40| 20 60 66 27 2c 20 2e 2e | 2e 0d 20 20 20 20 20 20 | `f', ..|.. |
|00001b50| 4f 74 68 65 72 20 6c 65 | 74 74 65 72 73 20 63 61 |Other le|tters ca|
|00001b60| 6e 20 62 65 20 64 65 66 | 69 6e 65 64 20 69 6e 20 |n be def|ined in |
|00001b70| 6d 61 63 68 69 6e 65 2d | 64 65 70 65 6e 64 65 6e |machine-|dependen|
|00001b80| 74 20 66 61 73 68 69 6f | 6e 20 74 6f 0d 20 20 20 |t fashio|n to. |
|00001b90| 20 20 73 74 61 6e 64 20 | 66 6f 72 20 70 61 72 74 | stand |for part|
|00001ba0| 69 63 75 6c 61 72 20 63 | 6c 61 73 73 65 73 20 6f |icular c|lasses o|
|00001bb0| 66 20 72 65 67 69 73 74 | 65 72 73 2e 20 20 60 64 |f regist|ers. `d|
|00001bc0| 27 2c 20 60 61 27 20 61 | 6e 64 20 60 66 27 20 61 |', `a' a|nd `f' a|
|00001bd0| 72 65 0d 20 20 20 20 20 | 64 65 66 69 6e 65 64 20 |re. |defined |
|00001be0| 6f 6e 20 74 68 65 20 36 | 38 30 30 30 2f 36 38 30 |on the 6|8000/680|
|00001bf0| 32 30 20 74 6f 20 73 74 | 61 6e 64 20 66 6f 72 20 |20 to st|and for |
|00001c00| 64 61 74 61 2c 20 61 64 | 64 72 65 73 73 20 61 6e |data, ad|dress an|
|00001c10| 64 0d 20 20 20 20 20 66 | 6c 6f 61 74 69 6e 67 20 |d. f|loating |
|00001c20| 70 6f 69 6e 74 20 72 65 | 67 69 73 74 65 72 73 2e |point re|gisters.|
|00001c30| 0d 0d 60 69 27 0d 20 20 | 20 20 20 41 6e 20 69 6d |..`i'. | An im|
|00001c40| 6d 65 64 69 61 74 65 20 | 69 6e 74 65 67 65 72 20 |mediate |integer |
|00001c50| 6f 70 65 72 61 6e 64 20 | 28 6f 6e 65 20 77 69 74 |operand |(one wit|
|00001c60| 68 20 63 6f 6e 73 74 61 | 6e 74 20 76 61 6c 75 65 |h consta|nt value|
|00001c70| 29 20 69 73 20 61 6c 6c | 6f 77 65 64 2e 0d 20 20 |) is all|owed.. |
|00001c80| 20 20 20 54 68 69 73 20 | 69 6e 63 6c 75 64 65 73 | This |includes|
|00001c90| 20 73 79 6d 62 6f 6c 69 | 63 20 63 6f 6e 73 74 61 | symboli|c consta|
|00001ca0| 6e 74 73 20 77 68 6f 73 | 65 20 76 61 6c 75 65 73 |nts whos|e values|
|00001cb0| 20 77 69 6c 6c 20 62 65 | 20 6b 6e 6f 77 6e 20 6f | will be| known o|
|00001cc0| 6e 6c 79 0d 20 20 20 20 | 20 61 74 20 61 73 73 65 |nly. | at asse|
|00001cd0| 6d 62 6c 79 20 74 69 6d | 65 2e 0d 0d 60 6e 27 0d |mbly tim|e...`n'.|
|00001ce0| 20 20 20 20 20 41 6e 20 | 69 6d 6d 65 64 69 61 74 | An |immediat|
|00001cf0| 65 20 69 6e 74 65 67 65 | 72 20 6f 70 65 72 61 6e |e intege|r operan|
|00001d00| 64 20 77 69 74 68 20 61 | 20 6b 6e 6f 77 6e 20 6e |d with a| known n|
|00001d10| 75 6d 65 72 69 63 20 76 | 61 6c 75 65 20 69 73 0d |umeric v|alue is.|
|00001d20| 20 20 20 20 20 61 6c 6c | 6f 77 65 64 2e 20 20 4d | all|owed. M|
|00001d30| 61 6e 79 20 73 79 73 74 | 65 6d 73 20 63 61 6e 6e |any syst|ems cann|
|00001d40| 6f 74 20 73 75 70 70 6f | 72 74 20 61 73 73 65 6d |ot suppo|rt assem|
|00001d50| 62 6c 79 2d 74 69 6d 65 | 20 63 6f 6e 73 74 61 6e |bly-time| constan|
|00001d60| 74 73 0d 20 20 20 20 20 | 66 6f 72 20 6f 70 65 72 |ts. |for oper|
|00001d70| 61 6e 64 73 20 6c 65 73 | 73 20 74 68 61 6e 20 61 |ands les|s than a|
|00001d80| 20 77 6f 72 64 20 77 69 | 64 65 2e 20 20 43 6f 6e | word wi|de. Con|
|00001d90| 73 74 72 61 69 6e 74 73 | 20 66 6f 72 20 74 68 65 |straints| for the|
|00001da0| 73 65 0d 20 20 20 20 20 | 6f 70 65 72 61 6e 64 73 |se. |operands|
|00001db0| 20 73 68 6f 75 6c 64 20 | 75 73 65 20 60 6e 27 20 | should |use `n' |
|00001dc0| 72 61 74 68 65 72 20 74 | 68 61 6e 20 60 69 27 2e |rather t|han `i'.|
|00001dd0| 0d 0d 60 49 27 2c 20 60 | 4a 27 2c 20 60 4b 27 2c |..`I', `|J', `K',|
|00001de0| 20 2e 2e 2e 0d 20 20 20 | 20 20 20 4f 74 68 65 72 | .... | Other|
|00001df0| 20 6c 65 74 74 65 72 73 | 20 69 6e 20 74 68 65 20 | letters| in the |
|00001e00| 72 61 6e 67 65 20 60 49 | 27 20 74 68 72 6f 75 67 |range `I|' throug|
|00001e10| 68 20 60 4d 27 20 6d 61 | 79 20 62 65 20 64 65 66 |h `M' ma|y be def|
|00001e20| 69 6e 65 64 20 69 6e 20 | 61 0d 20 20 20 20 20 6d |ined in |a. m|
|00001e30| 61 63 68 69 6e 65 2d 64 | 65 70 65 6e 64 65 6e 74 |achine-d|ependent|
|00001e40| 20 66 61 73 68 69 6f 6e | 20 74 6f 20 70 65 72 6d | fashion| to perm|
|00001e50| 69 74 20 69 6d 6d 65 64 | 69 61 74 65 20 69 6e 74 |it immed|iate int|
|00001e60| 65 67 65 72 20 6f 70 65 | 72 61 6e 64 73 0d 20 20 |eger ope|rands. |
|00001e70| 20 20 20 77 69 74 68 20 | 65 78 70 6c 69 63 69 74 | with |explicit|
|00001e80| 20 69 6e 74 65 67 65 72 | 20 76 61 6c 75 65 73 20 | integer| values |
|00001e90| 69 6e 20 73 70 65 63 69 | 66 69 65 64 20 72 61 6e |in speci|fied ran|
|00001ea0| 67 65 73 2e 20 20 46 6f | 72 20 65 78 61 6d 70 6c |ges. Fo|r exampl|
|00001eb0| 65 2c 0d 20 20 20 20 20 | 6f 6e 20 74 68 65 20 36 |e,. |on the 6|
|00001ec0| 38 30 30 30 2c 20 60 49 | 27 20 69 73 20 64 65 66 |8000, `I|' is def|
|00001ed0| 69 6e 65 64 20 74 6f 20 | 73 74 61 6e 64 20 66 6f |ined to |stand fo|
|00001ee0| 72 20 74 68 65 20 72 61 | 6e 67 65 20 6f 66 20 76 |r the ra|nge of v|
|00001ef0| 61 6c 75 65 73 20 31 0d | 20 20 20 20 20 74 6f 20 |alues 1.| to |
|00001f00| 38 2e 20 20 54 68 69 73 | 20 69 73 20 74 68 65 20 |8. This| is the |
|00001f10| 72 61 6e 67 65 20 70 65 | 72 6d 69 74 74 65 64 20 |range pe|rmitted |
|00001f20| 61 73 20 61 20 73 68 69 | 66 74 20 63 6f 75 6e 74 |as a shi|ft count|
|00001f30| 20 69 6e 20 74 68 65 20 | 73 68 69 66 74 0d 20 20 | in the |shift. |
|00001f40| 20 20 20 69 6e 73 74 72 | 75 63 74 69 6f 6e 73 2e | instr|uctions.|
|00001f50| 0d 0d 60 46 27 0d 20 20 | 20 20 20 41 6e 20 69 6d |..`F'. | An im|
|00001f60| 6d 65 64 69 61 74 65 20 | 66 6c 6f 61 74 69 6e 67 |mediate |floating|
|00001f70| 20 6f 70 65 72 61 6e 64 | 20 28 65 78 70 72 65 73 | operand| (expres|
|00001f80| 73 69 6f 6e 20 63 6f 64 | 65 20 60 63 6f 6e 73 74 |sion cod|e `const|
|00001f90| 5f 64 6f 75 62 6c 65 27 | 29 0d 20 20 20 20 20 69 |_double'|). i|
|00001fa0| 73 20 61 6c 6c 6f 77 65 | 64 2e 0d 0d 60 47 27 2c |s allowe|d...`G',|
|00001fb0| 20 60 48 27 0d 20 20 20 | 20 20 60 47 27 20 61 6e | `H'. | `G' an|
|00001fc0| 64 20 60 48 27 20 6d 61 | 79 20 62 65 20 64 65 66 |d `H' ma|y be def|
|00001fd0| 69 6e 65 64 20 69 6e 20 | 61 20 6d 61 63 68 69 6e |ined in |a machin|
|00001fe0| 65 2d 64 65 70 65 6e 64 | 65 6e 74 20 66 61 73 68 |e-depend|ent fash|
|00001ff0| 69 6f 6e 20 74 6f 0d 20 | 20 20 20 20 70 65 72 6d |ion to. | perm|
|00002000| 69 74 20 69 6d 6d 65 64 | 69 61 74 65 20 66 6c 6f |it immed|iate flo|
|00002010| 61 74 69 6e 67 20 6f 70 | 65 72 61 6e 64 73 20 69 |ating op|erands i|
|00002020| 6e 20 70 61 72 74 69 63 | 75 6c 61 72 20 72 61 6e |n partic|ular ran|
|00002030| 67 65 73 20 6f 66 20 76 | 61 6c 75 65 73 2e 0d 0d |ges of v|alues...|
|00002040| 60 73 27 0d 20 20 20 20 | 20 41 6e 20 69 6d 6d 65 |`s'. | An imme|
|00002050| 64 69 61 74 65 20 69 6e | 74 65 67 65 72 20 6f 70 |diate in|teger op|
|00002060| 65 72 61 6e 64 20 77 68 | 6f 73 65 20 76 61 6c 75 |erand wh|ose valu|
|00002070| 65 20 69 73 20 6e 6f 74 | 20 61 6e 20 65 78 70 6c |e is not| an expl|
|00002080| 69 63 69 74 0d 20 20 20 | 20 20 69 6e 74 65 67 65 |icit. | intege|
|00002090| 72 20 69 73 20 61 6c 6c | 6f 77 65 64 2e 0d 0d 20 |r is all|owed... |
|000020a0| 20 20 20 20 54 68 69 73 | 20 6d 69 67 68 74 20 61 | This| might a|
|000020b0| 70 70 65 61 72 20 73 74 | 72 61 6e 67 65 3b 20 69 |ppear st|range; i|
|000020c0| 66 20 61 6e 20 69 6e 73 | 6e 20 61 6c 6c 6f 77 73 |f an ins|n allows|
|000020d0| 20 61 20 63 6f 6e 73 74 | 61 6e 74 20 6f 70 65 72 | a const|ant oper|
|000020e0| 61 6e 64 0d 20 20 20 20 | 20 77 69 74 68 20 61 20 |and. | with a |
|000020f0| 76 61 6c 75 65 20 6e 6f | 74 20 6b 6e 6f 77 6e 20 |value no|t known |
|00002100| 61 74 20 63 6f 6d 70 69 | 6c 65 20 74 69 6d 65 2c |at compi|le time,|
|00002110| 20 69 74 20 63 65 72 74 | 61 69 6e 6c 79 20 6d 75 | it cert|ainly mu|
|00002120| 73 74 20 61 6c 6c 6f 77 | 0d 20 20 20 20 20 61 6e |st allow|. an|
|00002130| 79 20 6b 6e 6f 77 6e 20 | 76 61 6c 75 65 2e 20 20 |y known |value. |
|00002140| 53 6f 20 77 68 79 20 75 | 73 65 20 60 73 27 20 69 |So why u|se `s' i|
|00002150| 6e 73 74 65 61 64 20 6f | 66 20 60 69 27 3f 20 20 |nstead o|f `i'? |
|00002160| 53 6f 6d 65 74 69 6d 65 | 73 20 69 74 0d 20 20 20 |Sometime|s it. |
|00002170| 20 20 61 6c 6c 6f 77 73 | 20 62 65 74 74 65 72 20 | allows| better |
|00002180| 63 6f 64 65 20 74 6f 20 | 62 65 20 67 65 6e 65 72 |code to |be gener|
|00002190| 61 74 65 64 2e 0d 0d 20 | 20 20 20 20 46 6f 72 20 |ated... | For |
|000021a0| 65 78 61 6d 70 6c 65 2c | 20 6f 6e 20 74 68 65 20 |example,| on the |
|000021b0| 36 38 30 30 30 20 69 6e | 20 61 20 66 75 6c 6c 77 |68000 in| a fullw|
|000021c0| 6f 72 64 20 69 6e 73 74 | 72 75 63 74 69 6f 6e 20 |ord inst|ruction |
|000021d0| 69 74 20 69 73 0d 20 20 | 20 20 20 70 6f 73 73 69 |it is. | possi|
|000021e0| 62 6c 65 20 74 6f 20 75 | 73 65 20 61 6e 20 69 6d |ble to u|se an im|
|000021f0| 6d 65 64 69 61 74 65 20 | 6f 70 65 72 61 6e 64 3b |mediate |operand;|
|00002200| 20 62 75 74 20 69 66 20 | 74 68 65 20 69 6d 6d 65 | but if |the imme|
|00002210| 64 69 61 74 65 20 76 61 | 6c 75 65 0d 20 20 20 20 |diate va|lue. |
|00002220| 20 69 73 20 62 65 74 77 | 65 65 6e 20 2d 31 32 38 | is betw|een -128|
|00002230| 20 61 6e 64 20 31 32 37 | 2c 20 62 65 74 74 65 72 | and 127|, better|
|00002240| 20 63 6f 64 65 20 72 65 | 73 75 6c 74 73 20 66 72 | code re|sults fr|
|00002250| 6f 6d 20 6c 6f 61 64 69 | 6e 67 20 74 68 65 0d 20 |om loadi|ng the. |
|00002260| 20 20 20 20 76 61 6c 75 | 65 20 69 6e 74 6f 20 61 | valu|e into a|
|00002270| 20 72 65 67 69 73 74 65 | 72 20 61 6e 64 20 75 73 | registe|r and us|
|00002280| 69 6e 67 20 74 68 65 20 | 72 65 67 69 73 74 65 72 |ing the |register|
|00002290| 2e 20 20 54 68 69 73 20 | 69 73 20 62 65 63 61 75 |. This |is becau|
|000022a0| 73 65 0d 20 20 20 20 20 | 74 68 65 20 6c 6f 61 64 |se. |the load|
|000022b0| 20 69 6e 74 6f 20 74 68 | 65 20 72 65 67 69 73 74 | into th|e regist|
|000022c0| 65 72 20 63 61 6e 20 62 | 65 20 64 6f 6e 65 20 77 |er can b|e done w|
|000022d0| 69 74 68 20 61 20 60 6d | 6f 76 65 71 27 0d 20 20 |ith a `m|oveq'. |
|000022e0| 20 20 20 69 6e 73 74 72 | 75 63 74 69 6f 6e 2e 20 | instr|uction. |
|000022f0| 20 57 65 20 61 72 72 61 | 6e 67 65 20 66 6f 72 20 | We arra|nge for |
|00002300| 74 68 69 73 20 74 6f 20 | 68 61 70 70 65 6e 20 62 |this to |happen b|
|00002310| 79 20 64 65 66 69 6e 69 | 6e 67 20 74 68 65 0d 20 |y defini|ng the. |
|00002320| 20 20 20 20 6c 65 74 74 | 65 72 20 60 4b 27 20 74 | lett|er `K' t|
|00002330| 6f 20 6d 65 61 6e 20 60 | 60 61 6e 79 20 69 6e 74 |o mean `|`any int|
|00002340| 65 67 65 72 20 6f 75 74 | 73 69 64 65 20 74 68 65 |eger out|side the|
|00002350| 20 72 61 6e 67 65 20 2d | 31 32 38 20 74 6f 0d 20 | range -|128 to. |
|00002360| 20 20 20 20 31 32 37 27 | 27 2c 20 61 6e 64 20 74 | 127'|', and t|
|00002370| 68 65 6e 20 73 70 65 63 | 69 66 79 69 6e 67 20 60 |hen spec|ifying `|
|00002380| 4b 73 27 20 69 6e 20 74 | 68 65 20 6f 70 65 72 61 |Ks' in t|he opera|
|00002390| 6e 64 20 63 6f 6e 73 74 | 72 61 69 6e 74 73 2e 0d |nd const|raints..|
|000023a0| 0d 60 67 27 0d 20 20 20 | 20 20 41 6e 79 20 72 65 |.`g'. | Any re|
|000023b0| 67 69 73 74 65 72 2c 20 | 6d 65 6d 6f 72 79 20 6f |gister, |memory o|
|000023c0| 72 20 69 6d 6d 65 64 69 | 61 74 65 20 69 6e 74 65 |r immedi|ate inte|
|000023d0| 67 65 72 20 6f 70 65 72 | 61 6e 64 20 69 73 20 61 |ger oper|and is a|
|000023e0| 6c 6c 6f 77 65 64 2c 0d | 20 20 20 20 20 65 78 63 |llowed,.| exc|
|000023f0| 65 70 74 20 66 6f 72 20 | 72 65 67 69 73 74 65 72 |ept for |register|
|00002400| 73 20 74 68 61 74 20 61 | 72 65 20 6e 6f 74 20 67 |s that a|re not g|
|00002410| 65 6e 65 72 61 6c 20 72 | 65 67 69 73 74 65 72 73 |eneral r|egisters|
|00002420| 2e 0d 0d 60 4e 27 20 28 | 61 20 64 69 67 69 74 29 |...`N' (|a digit)|
|00002430| 0d 20 20 20 20 20 41 6e | 20 6f 70 65 72 61 6e 64 |. An| operand|
|00002440| 20 74 68 61 74 20 6d 61 | 74 63 68 65 73 20 6f 70 | that ma|tches op|
|00002450| 65 72 61 6e 64 20 6e 75 | 6d 62 65 72 20 4e 20 69 |erand nu|mber N i|
|00002460| 73 20 61 6c 6c 6f 77 65 | 64 2e 20 20 49 66 20 61 |s allowe|d. If a|
|00002470| 20 64 69 67 69 74 0d 20 | 20 20 20 20 69 73 20 75 | digit. | is u|
|00002480| 73 65 64 20 74 6f 67 65 | 74 68 65 72 20 77 69 74 |sed toge|ther wit|
|00002490| 68 20 6c 65 74 74 65 72 | 73 2c 20 74 68 65 20 64 |h letter|s, the d|
|000024a0| 69 67 69 74 20 73 68 6f | 75 6c 64 20 63 6f 6d 65 |igit sho|uld come|
|000024b0| 20 6c 61 73 74 2e 0d 0d | 20 20 20 20 20 54 68 69 | last...| Thi|
|000024c0| 73 20 69 73 20 63 61 6c | 6c 65 64 20 61 20 22 6d |s is cal|led a "m|
|000024d0| 61 74 63 68 69 6e 67 20 | 63 6f 6e 73 74 72 61 69 |atching |constrai|
|000024e0| 6e 74 22 20 61 6e 64 20 | 77 68 61 74 20 69 74 20 |nt" and |what it |
|000024f0| 72 65 61 6c 6c 79 20 6d | 65 61 6e 73 0d 20 20 20 |really m|eans. |
|00002500| 20 20 69 73 20 74 68 61 | 74 20 74 68 65 20 61 73 | is tha|t the as|
|00002510| 73 65 6d 62 6c 65 72 20 | 68 61 73 20 6f 6e 6c 79 |sembler |has only|
|00002520| 20 61 20 73 69 6e 67 6c | 65 20 6f 70 65 72 61 6e | a singl|e operan|
|00002530| 64 20 74 68 61 74 20 66 | 69 6c 6c 73 20 74 77 6f |d that f|ills two|
|00002540| 0d 20 20 20 20 20 72 6f | 6c 65 73 20 63 6f 6e 73 |. ro|les cons|
|00002550| 69 64 65 72 65 64 20 73 | 65 70 61 72 61 74 65 20 |idered s|eparate |
|00002560| 69 6e 20 74 68 65 20 52 | 54 4c 20 69 6e 73 6e 2e |in the R|TL insn.|
|00002570| 20 20 46 6f 72 20 65 78 | 61 6d 70 6c 65 2c 20 61 | For ex|ample, a|
|00002580| 6e 20 61 64 64 0d 20 20 | 20 20 20 69 6e 73 6e 20 |n add. | insn |
|00002590| 68 61 73 20 74 77 6f 20 | 69 6e 70 75 74 20 6f 70 |has two |input op|
|000025a0| 65 72 61 6e 64 73 20 61 | 6e 64 20 6f 6e 65 20 6f |erands a|nd one o|
|000025b0| 75 74 70 75 74 20 6f 70 | 65 72 61 6e 64 20 69 6e |utput op|erand in|
|000025c0| 20 74 68 65 20 52 54 4c | 2c 0d 20 20 20 20 20 62 | the RTL|,. b|
|000025d0| 75 74 20 6f 6e 20 6d 6f | 73 74 20 6d 61 63 68 69 |ut on mo|st machi|
|000025e0| 6e 65 73 20 61 6e 20 61 | 64 64 20 69 6e 73 74 72 |nes an a|dd instr|
|000025f0| 75 63 74 69 6f 6e 20 72 | 65 61 6c 6c 79 20 68 61 |uction r|eally ha|
|00002600| 73 20 6f 6e 6c 79 20 74 | 77 6f 0d 20 20 20 20 20 |s only t|wo. |
|00002610| 6f 70 65 72 61 6e 64 73 | 2c 20 6f 6e 65 20 6f 66 |operands|, one of|
|00002620| 20 74 68 65 6d 20 61 6e | 20 69 6e 70 75 74 2d 6f | them an| input-o|
|00002630| 75 74 70 75 74 20 6f 70 | 65 72 61 6e 64 2e 0d 0d |utput op|erand...|
|00002640| 20 20 20 20 20 4d 61 74 | 63 68 69 6e 67 20 63 6f | Mat|ching co|
|00002650| 6e 73 74 72 61 69 6e 74 | 73 20 77 6f 72 6b 20 6f |nstraint|s work o|
|00002660| 6e 6c 79 20 69 6e 20 63 | 69 72 63 75 6d 73 74 61 |nly in c|ircumsta|
|00002670| 6e 63 65 73 20 6c 69 6b | 65 20 74 68 61 74 20 61 |nces lik|e that a|
|00002680| 64 64 0d 20 20 20 20 20 | 69 6e 73 6e 2e 20 20 4d |dd. |insn. M|
|00002690| 6f 72 65 20 70 72 65 63 | 69 73 65 6c 79 2c 20 74 |ore prec|isely, t|
|000026a0| 68 65 20 6d 61 74 63 68 | 69 6e 67 20 63 6f 6e 73 |he match|ing cons|
|000026b0| 74 72 61 69 6e 74 20 6d | 75 73 74 20 61 70 70 65 |traint m|ust appe|
|000026c0| 61 72 20 69 6e 20 61 6e | 0d 20 20 20 20 20 69 6e |ar in an|. in|
|000026d0| 70 75 74 2d 6f 6e 6c 79 | 20 6f 70 65 72 61 6e 64 |put-only| operand|
|000026e0| 20 61 6e 64 20 74 68 65 | 20 6f 70 65 72 61 6e 64 | and the| operand|
|000026f0| 20 74 68 61 74 20 69 74 | 20 6d 61 74 63 68 65 73 | that it| matches|
|00002700| 20 6d 75 73 74 20 62 65 | 20 61 6e 0d 20 20 20 20 | must be| an. |
|00002710| 20 6f 75 74 70 75 74 2d | 6f 6e 6c 79 20 6f 70 65 | output-|only ope|
|00002720| 72 61 6e 64 20 77 69 74 | 68 20 61 20 6c 6f 77 65 |rand wit|h a lowe|
|00002730| 72 20 6e 75 6d 62 65 72 | 2e 20 20 54 68 75 73 2c |r number|. Thus,|
|00002740| 20 6f 70 65 72 61 6e 64 | 20 4e 20 6d 75 73 74 0d | operand| N must.|
|00002750| 20 20 20 20 20 68 61 76 | 65 20 60 3d 27 20 69 6e | hav|e `=' in|
|00002760| 20 69 74 73 20 63 6f 6e | 73 74 72 61 69 6e 74 2e | its con|straint.|
|00002770| 0d 0d 20 20 20 20 20 46 | 6f 72 20 6f 70 65 72 61 |.. F|or opera|
|00002780| 6e 64 73 20 74 6f 20 6d | 61 74 63 68 20 69 6e 20 |nds to m|atch in |
|00002790| 61 20 70 61 72 74 69 63 | 75 6c 61 72 20 63 61 73 |a partic|ular cas|
|000027a0| 65 20 75 73 75 61 6c 6c | 79 20 6d 65 61 6e 73 20 |e usuall|y means |
|000027b0| 74 68 61 74 0d 20 20 20 | 20 20 74 68 65 79 20 61 |that. | they a|
|000027c0| 72 65 20 69 64 65 6e 74 | 69 63 61 6c 2d 6c 6f 6f |re ident|ical-loo|
|000027d0| 6b 69 6e 67 20 52 54 4c | 20 65 78 70 72 65 73 73 |king RTL| express|
|000027e0| 69 6f 6e 73 2e 20 20 42 | 75 74 20 69 6e 20 61 20 |ions. B|ut in a |
|000027f0| 66 65 77 0d 20 20 20 20 | 20 73 70 65 63 69 61 6c |few. | special|
|00002800| 20 63 61 73 65 73 20 73 | 70 65 63 69 66 69 63 20 | cases s|pecific |
|00002810| 6b 69 6e 64 73 20 6f 66 | 20 64 69 73 73 69 6d 69 |kinds of| dissimi|
|00002820| 6c 61 72 69 74 79 20 61 | 72 65 20 61 6c 6c 6f 77 |larity a|re allow|
|00002830| 65 64 2e 20 20 46 6f 72 | 0d 20 20 20 20 20 65 78 |ed. For|. ex|
|00002840| 61 6d 70 6c 65 2c 20 60 | 2a 78 27 20 61 73 20 61 |ample, `|*x' as a|
|00002850| 6e 20 69 6e 70 75 74 20 | 6f 70 65 72 61 6e 64 20 |n input |operand |
|00002860| 77 69 6c 6c 20 6d 61 74 | 63 68 20 60 2a 78 2b 2b |will mat|ch `*x++|
|00002870| 27 20 61 73 20 61 6e 20 | 6f 75 74 70 75 74 0d 20 |' as an |output. |
|00002880| 20 20 20 20 6f 70 65 72 | 61 6e 64 2e 20 20 46 6f | oper|and. Fo|
|00002890| 72 20 70 72 6f 70 65 72 | 20 72 65 73 75 6c 74 73 |r proper| results|
|000028a0| 20 69 6e 20 73 75 63 68 | 20 63 61 73 65 73 2c 20 | in such| cases, |
|000028b0| 74 68 65 20 6f 75 74 70 | 75 74 20 74 65 6d 70 6c |the outp|ut templ|
|000028c0| 61 74 65 0d 20 20 20 20 | 20 73 68 6f 75 6c 64 20 |ate. | should |
|000028d0| 61 6c 77 61 79 73 20 75 | 73 65 20 74 68 65 20 6f |always u|se the o|
|000028e0| 75 74 70 75 74 2d 6f 70 | 65 72 61 6e 64 27 73 20 |utput-op|erand's |
|000028f0| 6e 75 6d 62 65 72 20 77 | 68 65 6e 20 70 72 69 6e |number w|hen prin|
|00002900| 74 69 6e 67 20 74 68 65 | 0d 20 20 20 20 20 6f 70 |ting the|. op|
|00002910| 65 72 61 6e 64 2e 0d 0d | 60 70 27 0d 20 20 20 20 |erand...|`p'. |
|00002920| 20 41 6e 20 6f 70 65 72 | 61 6e 64 20 74 68 61 74 | An oper|and that|
|00002930| 20 69 73 20 61 20 76 61 | 6c 69 64 20 6d 65 6d 6f | is a va|lid memo|
|00002940| 72 79 20 61 64 64 72 65 | 73 73 20 69 73 20 61 6c |ry addre|ss is al|
|00002950| 6c 6f 77 65 64 2e 20 20 | 54 68 69 73 20 69 73 0d |lowed. |This is.|
|00002960| 20 20 20 20 20 66 6f 72 | 20 60 60 6c 6f 61 64 20 | for| ``load |
|00002970| 61 64 64 72 65 73 73 27 | 27 20 61 6e 64 20 60 60 |address'|' and ``|
|00002980| 70 75 73 68 20 61 64 64 | 72 65 73 73 27 27 20 69 |push add|ress'' i|
|00002990| 6e 73 74 72 75 63 74 69 | 6f 6e 73 2e 0d 0d 20 20 |nstructi|ons... |
|000029a0| 20 20 20 60 70 27 20 69 | 6e 20 74 68 65 20 63 6f | `p' i|n the co|
|000029b0| 6e 73 74 72 61 69 6e 74 | 20 6d 75 73 74 20 62 65 |nstraint| must be|
|000029c0| 20 61 63 63 6f 6d 70 61 | 6e 69 65 73 20 62 79 20 | accompa|nies by |
|000029d0| 60 61 64 64 72 65 73 73 | 5f 6f 70 65 72 61 6e 64 |`address|_operand|
|000029e0| 27 0d 20 20 20 20 20 61 | 73 20 74 68 65 20 70 72 |'. a|s the pr|
|000029f0| 65 64 69 63 61 74 65 20 | 69 6e 20 74 68 65 20 60 |edicate |in the `|
|00002a00| 6d 61 74 63 68 5f 6f 70 | 65 72 61 6e 64 27 2e 0d |match_op|erand'..|
|00002a10| 0d 49 6e 20 6f 72 64 65 | 72 20 74 6f 20 68 61 76 |.In orde|r to hav|
|00002a20| 65 20 76 61 6c 69 64 20 | 61 73 73 65 6d 62 6c 65 |e valid |assemble|
|00002a30| 72 20 63 6f 64 65 2c 20 | 65 61 63 68 20 6f 70 65 |r code, |each ope|
|00002a40| 72 61 6e 64 20 6d 75 73 | 74 20 73 61 74 69 73 66 |rand mus|t satisf|
|00002a50| 79 20 69 74 73 0d 63 6f | 6e 73 74 72 61 69 6e 74 |y its.co|nstraint|
|00002a60| 2e 20 20 42 75 74 20 61 | 20 66 61 69 6c 75 72 65 |. But a| failure|
|00002a70| 20 74 6f 20 64 6f 20 73 | 6f 20 64 6f 65 73 20 6e | to do s|o does n|
|00002a80| 6f 74 20 70 72 65 76 65 | 6e 74 20 74 68 65 20 70 |ot preve|nt the p|
|00002a90| 61 74 74 65 72 6e 20 66 | 72 6f 6d 0d 61 70 70 6c |attern f|rom.appl|
|00002aa0| 79 69 6e 67 20 74 6f 20 | 61 6e 20 69 6e 73 6e 2e |ying to |an insn.|
|00002ab0| 20 20 49 6e 73 74 65 61 | 64 2c 20 69 74 20 64 69 | Instea|d, it di|
|00002ac0| 72 65 63 74 73 20 74 68 | 65 20 63 6f 6d 70 69 6c |rects th|e compil|
|00002ad0| 65 72 20 74 6f 20 6d 6f | 64 69 66 79 20 74 68 65 |er to mo|dify the|
|00002ae0| 0d 63 6f 64 65 20 73 6f | 20 74 68 61 74 20 74 68 |.code so| that th|
|00002af0| 65 20 63 6f 6e 73 74 72 | 61 69 6e 74 20 77 69 6c |e constr|aint wil|
|00002b00| 6c 20 62 65 20 73 61 74 | 69 73 66 69 65 64 2e 20 |l be sat|isfied. |
|00002b10| 20 55 73 75 61 6c 6c 79 | 20 74 68 69 73 20 69 73 | Usually| this is|
|00002b20| 20 64 6f 6e 65 0d 62 79 | 20 63 6f 70 79 69 6e 67 | done.by| copying|
|00002b30| 20 61 6e 20 6f 70 65 72 | 61 6e 64 20 69 6e 74 6f | an oper|and into|
|00002b40| 20 61 20 72 65 67 69 73 | 74 65 72 2e 0d 0d 43 6f | a regis|ter...Co|
|00002b50| 6e 74 72 61 73 74 2c 20 | 74 68 65 72 65 66 6f 72 |ntrast, |therefor|
|00002b60| 65 2c 20 74 68 65 20 74 | 77 6f 20 69 6e 73 74 72 |e, the t|wo instr|
|00002b70| 75 63 74 69 6f 6e 20 70 | 61 74 74 65 72 6e 73 20 |uction p|atterns |
|00002b80| 74 68 61 74 20 66 6f 6c | 6c 6f 77 3a 0d 0d 20 20 |that fol|low:.. |
|00002b90| 20 20 20 28 64 65 66 69 | 6e 65 5f 69 6e 73 6e 20 | (defi|ne_insn |
|00002ba0| 22 22 0d 20 20 20 20 20 | 20 20 5b 28 73 65 74 20 |"". | [(set |
|00002bb0| 28 6d 61 74 63 68 5f 6f | 70 65 72 61 6e 64 3a 53 |(match_o|perand:S|
|00002bc0| 49 20 30 20 22 67 65 6e | 65 72 61 6c 5f 6f 70 65 |I 0 "gen|eral_ope|
|00002bd0| 72 61 6e 64 22 20 22 72 | 22 29 0d 20 20 20 20 20 |rand" "r|"). |
|00002be0| 20 20 20 20 20 20 20 20 | 28 70 6c 75 73 3a 53 49 | |(plus:SI|
|00002bf0| 20 28 6d 61 74 63 68 5f | 64 75 70 20 30 29 0d 20 | (match_|dup 0). |
|00002c00| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|00002c10| 20 20 20 20 20 28 6d 61 | 74 63 68 5f 6f 70 65 72 | (ma|tch_oper|
|00002c20| 61 6e 64 3a 53 49 20 31 | 20 22 67 65 6e 65 72 61 |and:SI 1| "genera|
|00002c30| 6c 5f 6f 70 65 72 61 6e | 64 22 20 22 72 22 29 29 |l_operan|d" "r"))|
|00002c40| 29 5d 0d 20 20 20 20 20 | 20 20 22 22 0d 20 20 20 |)]. | "". |
|00002c50| 20 20 20 20 22 2e 2e 2e | 22 29 0d 0d 77 68 69 63 | "...|")..whic|
|00002c60| 68 20 68 61 73 20 74 77 | 6f 20 6f 70 65 72 61 6e |h has tw|o operan|
|00002c70| 64 73 2c 20 6f 6e 65 20 | 6f 66 20 77 68 69 63 68 |ds, one |of which|
|00002c80| 20 6d 75 73 74 20 61 70 | 70 65 61 72 20 69 6e 20 | must ap|pear in |
|00002c90| 74 77 6f 20 70 6c 61 63 | 65 73 2c 20 61 6e 64 0d |two plac|es, and.|
|00002ca0| 0d 20 20 20 20 20 28 64 | 65 66 69 6e 65 5f 69 6e |. (d|efine_in|
|00002cb0| 73 6e 20 22 22 0d 20 20 | 20 20 20 20 20 5b 28 73 |sn "". | [(s|
|00002cc0| 65 74 20 28 6d 61 74 63 | 68 5f 6f 70 65 72 61 6e |et (matc|h_operan|
|00002cd0| 64 3a 53 49 20 30 20 22 | 67 65 6e 65 72 61 6c 5f |d:SI 0 "|general_|
|00002ce0| 6f 70 65 72 61 6e 64 22 | 20 22 72 22 29 0d 20 20 |operand"| "r"). |
|00002cf0| 20 20 20 20 20 20 20 20 | 20 20 20 28 70 6c 75 73 | | (plus|
|00002d00| 3a 53 49 20 28 6d 61 74 | 63 68 5f 6f 70 65 72 61 |:SI (mat|ch_opera|
|00002d10| 6e 64 3a 53 49 20 31 20 | 22 67 65 6e 65 72 61 6c |nd:SI 1 |"general|
|00002d20| 5f 6f 70 65 72 61 6e 64 | 22 20 22 30 22 29 0d 20 |_operand|" "0"). |
|00002d30| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|00002d40| 20 20 20 20 20 28 6d 61 | 74 63 68 5f 6f 70 65 72 | (ma|tch_oper|
|00002d50| 61 6e 64 3a 53 49 20 32 | 20 22 67 65 6e 65 72 61 |and:SI 2| "genera|
|00002d60| 6c 5f 6f 70 65 72 61 6e | 64 22 20 22 72 22 29 29 |l_operan|d" "r"))|
|00002d70| 29 5d 0d 20 20 20 20 20 | 20 20 22 22 0d 20 20 20 |)]. | "". |
|00002d80| 20 20 20 20 22 2e 2e 2e | 22 29 0d 0d 77 68 69 63 | "...|")..whic|
|00002d90| 68 20 68 61 73 20 74 68 | 72 65 65 20 6f 70 65 72 |h has th|ree oper|
|00002da0| 61 6e 64 73 2c 20 74 77 | 6f 20 6f 66 20 77 68 69 |ands, tw|o of whi|
|00002db0| 63 68 20 61 72 65 20 72 | 65 71 75 69 72 65 64 20 |ch are r|equired |
|00002dc0| 62 79 20 61 20 63 6f 6e | 73 74 72 61 69 6e 74 0d |by a con|straint.|
|00002dd0| 74 6f 20 62 65 20 69 64 | 65 6e 74 69 63 61 6c 2e |to be id|entical.|
|00002de0| 20 20 49 66 20 77 65 20 | 61 72 65 20 63 6f 6e 73 | If we |are cons|
|00002df0| 69 64 65 72 69 6e 67 20 | 61 6e 20 69 6e 73 6e 20 |idering |an insn |
|00002e00| 6f 66 20 74 68 65 20 66 | 6f 72 6d 0d 0d 20 20 20 |of the f|orm.. |
|00002e10| 20 20 28 69 6e 73 6e 20 | 4e 20 50 52 45 56 20 4e | (insn |N PREV N|
|00002e20| 45 58 54 0d 20 20 20 20 | 20 20 20 28 73 65 74 20 |EXT. | (set |
|00002e30| 28 72 65 67 3a 53 49 20 | 33 29 0d 20 20 20 20 20 |(reg:SI |3). |
|00002e40| 20 20 20 20 20 20 20 28 | 70 6c 75 73 3a 53 49 20 | (|plus:SI |
|00002e50| 28 72 65 67 3a 53 49 20 | 36 29 20 28 72 65 67 3a |(reg:SI |6) (reg:|
|00002e60| 53 49 20 31 30 39 29 29 | 29 0d 20 20 20 20 20 20 |SI 109))|). |
|00002e70| 20 2e 2e 2e 29 0d 0d 74 | 68 65 20 66 69 72 73 74 | ...)..t|he first|
|00002e80| 20 70 61 74 74 65 72 6e | 20 77 6f 75 6c 64 20 6e | pattern| would n|
|00002e90| 6f 74 20 61 70 70 6c 79 | 20 61 74 20 61 6c 6c 2c |ot apply| at all,|
|00002ea0| 20 62 65 63 61 75 73 65 | 20 74 68 69 73 20 69 6e | because| this in|
|00002eb0| 73 6e 20 64 6f 65 73 20 | 6e 6f 74 0d 63 6f 6e 74 |sn does |not.cont|
|00002ec0| 61 69 6e 20 74 77 6f 20 | 69 64 65 6e 74 69 63 61 |ain two |identica|
|00002ed0| 6c 20 73 75 62 65 78 70 | 72 65 73 73 69 6f 6e 73 |l subexp|ressions|
|00002ee0| 20 69 6e 20 74 68 65 20 | 72 69 67 68 74 20 70 6c | in the |right pl|
|00002ef0| 61 63 65 2e 20 20 54 68 | 65 20 70 61 74 74 65 72 |ace. Th|e patter|
|00002f00| 6e 0d 77 6f 75 6c 64 20 | 73 61 79 2c 20 60 60 54 |n.would |say, ``T|
|00002f10| 68 61 74 20 64 6f 65 73 | 20 6e 6f 74 20 6c 6f 6f |hat does| not loo|
|00002f20| 6b 20 6c 69 6b 65 20 61 | 6e 20 61 64 64 20 69 6e |k like a|n add in|
|00002f30| 73 74 72 75 63 74 69 6f | 6e 3b 20 74 72 79 20 6f |structio|n; try o|
|00002f40| 74 68 65 72 0d 70 61 74 | 74 65 72 6e 73 2e 27 27 |ther.pat|terns.''|
|00002f50| 20 54 68 65 20 73 65 63 | 6f 6e 64 20 70 61 74 74 | The sec|ond patt|
|00002f60| 65 72 6e 20 77 6f 75 6c | 64 20 73 61 79 2c 20 60 |ern woul|d say, `|
|00002f70| 60 59 65 73 2c 20 74 68 | 61 74 27 73 20 61 6e 20 |`Yes, th|at's an |
|00002f80| 61 64 64 0d 69 6e 73 74 | 72 75 63 74 69 6f 6e 2c |add.inst|ruction,|
|00002f90| 20 62 75 74 20 74 68 65 | 72 65 20 69 73 20 73 6f | but the|re is so|
|00002fa0| 6d 65 74 68 69 6e 67 20 | 77 72 6f 6e 67 20 77 69 |mething |wrong wi|
|00002fb0| 74 68 20 69 74 2e 27 27 | 20 20 49 74 20 77 6f 75 |th it.''| It wou|
|00002fc0| 6c 64 20 64 69 72 65 63 | 74 0d 74 68 65 20 72 65 |ld direc|t.the re|
|00002fd0| 6c 6f 61 64 20 70 61 73 | 73 20 6f 66 20 74 68 65 |load pas|s of the|
|00002fe0| 20 63 6f 6d 70 69 6c 65 | 72 20 74 6f 20 67 65 6e | compile|r to gen|
|00002ff0| 65 72 61 74 65 20 61 64 | 64 69 74 69 6f 6e 61 6c |erate ad|ditional|
|00003000| 20 69 6e 73 6e 73 20 74 | 6f 20 6d 61 6b 65 0d 74 | insns t|o make.t|
|00003010| 68 65 20 63 6f 6e 73 74 | 72 61 69 6e 74 20 74 72 |he const|raint tr|
|00003020| 75 65 2e 20 20 54 68 65 | 20 72 65 73 75 6c 74 73 |ue. The| results|
|00003030| 20 6d 69 67 68 74 20 6c | 6f 6f 6b 20 6c 69 6b 65 | might l|ook like|
|00003040| 20 74 68 69 73 3a 0d 0d | 20 20 20 20 20 28 69 6e | this:..| (in|
|00003050| 73 6e 20 4e 32 20 50 52 | 45 56 20 4e 0d 20 20 20 |sn N2 PR|EV N. |
|00003060| 20 20 20 20 28 73 65 74 | 20 28 72 65 67 3a 53 49 | (set| (reg:SI|
|00003070| 20 33 29 20 28 72 65 67 | 3a 53 49 20 36 29 29 0d | 3) (reg|:SI 6)).|
|00003080| 20 20 20 20 20 20 20 2e | 2e 2e 29 0d 20 20 20 20 | .|..). |
|00003090| 20 0d 20 20 20 20 20 28 | 69 6e 73 6e 20 4e 20 4e | . (|insn N N|
|000030a0| 32 20 4e 45 58 54 0d 20 | 20 20 20 20 20 20 28 73 |2 NEXT. | (s|
|000030b0| 65 74 20 28 72 65 67 3a | 53 49 20 33 29 0d 20 20 |et (reg:|SI 3). |
|000030c0| 20 20 20 20 20 20 20 20 | 20 20 28 70 6c 75 73 3a | | (plus:|
|000030d0| 53 49 20 28 72 65 67 3a | 53 49 20 33 29 20 28 72 |SI (reg:|SI 3) (r|
|000030e0| 65 67 3a 53 49 20 31 30 | 39 29 29 29 0d 20 20 20 |eg:SI 10|9))). |
|000030f0| 20 20 20 20 2e 2e 2e 29 | 0d 0d 49 74 20 69 73 20 | ...)|..It is |
|00003100| 75 70 20 74 6f 20 79 6f | 75 20 74 6f 20 6d 61 6b |up to yo|u to mak|
|00003110| 65 20 73 75 72 65 20 74 | 68 61 74 20 65 61 63 68 |e sure t|hat each|
|00003120| 20 6f 70 65 72 61 6e 64 | 2c 20 69 6e 20 65 61 63 | operand|, in eac|
|00003130| 68 20 70 61 74 74 65 72 | 6e 2c 20 68 61 73 0d 63 |h patter|n, has.c|
|00003140| 6f 6e 73 74 72 61 69 6e | 74 73 20 74 68 61 74 20 |onstrain|ts that |
|00003150| 63 61 6e 20 68 61 6e 64 | 6c 65 20 61 6e 79 20 52 |can hand|le any R|
|00003160| 54 4c 20 65 78 70 72 65 | 73 73 69 6f 6e 20 74 68 |TL expre|ssion th|
|00003170| 61 74 20 63 6f 75 6c 64 | 20 62 65 20 70 72 65 73 |at could| be pres|
|00003180| 65 6e 74 0d 66 6f 72 20 | 74 68 61 74 20 6f 70 65 |ent.for |that ope|
|00003190| 72 61 6e 64 2e 20 20 28 | 57 68 65 6e 20 6d 75 6c |rand. (|When mul|
|000031a0| 74 69 70 6c 65 20 61 6c | 74 65 72 6e 61 74 69 76 |tiple al|ternativ|
|000031b0| 65 73 20 61 72 65 20 69 | 6e 20 75 73 65 2c 20 65 |es are i|n use, e|
|000031c0| 61 63 68 0d 70 61 74 74 | 65 72 6e 20 6d 75 73 74 |ach.patt|ern must|
|000031d0| 2c 20 66 6f 72 20 65 61 | 63 68 20 70 6f 73 73 69 |, for ea|ch possi|
|000031e0| 62 6c 65 20 63 6f 6d 62 | 69 6e 61 74 69 6f 6e 20 |ble comb|ination |
|000031f0| 6f 66 20 6f 70 65 72 61 | 6e 64 20 65 78 70 72 65 |of opera|nd expre|
|00003200| 73 73 69 6f 6e 73 2c 0d | 68 61 76 65 20 61 74 20 |ssions,.|have at |
|00003210| 6c 65 61 73 74 20 6f 6e | 65 20 61 6c 74 65 72 6e |least on|e altern|
|00003220| 61 74 69 76 65 20 77 68 | 69 63 68 20 63 61 6e 20 |ative wh|ich can |
|00003230| 68 61 6e 64 6c 65 20 74 | 68 61 74 20 63 6f 6d 62 |handle t|hat comb|
|00003240| 69 6e 61 74 69 6f 6e 20 | 6f 66 0d 6f 70 65 72 61 |ination |of.opera|
|00003250| 6e 64 73 2e 29 20 20 54 | 68 65 20 63 6f 6e 73 74 |nds.) T|he const|
|00003260| 72 61 69 6e 74 73 20 64 | 6f 6e 27 74 20 6e 65 65 |raints d|on't nee|
|00003270| 64 20 74 6f 20 2a 61 6c | 6c 6f 77 2a 20 61 6e 79 |d to *al|low* any|
|00003280| 20 70 6f 73 73 69 62 6c | 65 0d 6f 70 65 72 61 6e | possibl|e.operan|
|00003290| 64 2d 2d 77 68 65 6e 20 | 74 68 69 73 20 69 73 20 |d--when |this is |
|000032a0| 74 68 65 20 63 61 73 65 | 2c 20 74 68 65 79 20 64 |the case|, they d|
|000032b0| 6f 20 6e 6f 74 20 63 6f | 6e 73 74 72 61 69 6e 2d |o not co|nstrain-|
|000032c0| 2d 62 75 74 20 74 68 65 | 79 20 6d 75 73 74 0d 61 |-but the|y must.a|
|000032d0| 74 20 6c 65 61 73 74 20 | 70 6f 69 6e 74 20 74 68 |t least |point th|
|000032e0| 65 20 77 61 79 20 74 6f | 20 72 65 6c 6f 61 64 69 |e way to| reloadi|
|000032f0| 6e 67 20 61 6e 79 20 70 | 6f 73 73 69 62 6c 65 20 |ng any p|ossible |
|00003300| 6f 70 65 72 61 6e 64 20 | 73 6f 20 74 68 61 74 20 |operand |so that |
|00003310| 69 74 0d 77 69 6c 6c 20 | 66 69 74 2e 0d 0d 20 20 |it.will |fit... |
|00003320| 20 2a 20 49 66 20 74 68 | 65 20 63 6f 6e 73 74 72 | * If th|e constr|
|00003330| 61 69 6e 74 20 61 63 63 | 65 70 74 73 20 77 68 61 |aint acc|epts wha|
|00003340| 74 65 76 65 72 20 6f 70 | 65 72 61 6e 64 73 20 74 |tever op|erands t|
|00003350| 68 65 20 70 72 65 64 69 | 63 61 74 65 0d 20 20 20 |he predi|cate. |
|00003360| 20 20 70 65 72 6d 69 74 | 73 2c 20 74 68 65 72 65 | permit|s, there|
|00003370| 20 69 73 20 6e 6f 20 70 | 72 6f 62 6c 65 6d 3a 20 | is no p|roblem: |
|00003380| 72 65 6c 6f 61 64 69 6e | 67 20 69 73 20 6e 65 76 |reloadin|g is nev|
|00003390| 65 72 20 6e 65 63 65 73 | 73 61 72 79 20 66 6f 72 |er neces|sary for|
|000033a0| 0d 20 20 20 20 20 74 68 | 69 73 20 6f 70 65 72 61 |. th|is opera|
|000033b0| 6e 64 2e 0d 0d 20 20 20 | 20 20 46 6f 72 20 65 78 |nd... | For ex|
|000033c0| 61 6d 70 6c 65 2c 20 61 | 6e 20 6f 70 65 72 61 6e |ample, a|n operan|
|000033d0| 64 20 77 68 6f 73 65 20 | 63 6f 6e 73 74 72 61 69 |d whose |constrai|
|000033e0| 6e 74 73 20 70 65 72 6d | 69 74 20 65 76 65 72 79 |nts perm|it every|
|000033f0| 74 68 69 6e 67 0d 20 20 | 20 20 20 65 78 63 65 70 |thing. | excep|
|00003400| 74 20 72 65 67 69 73 74 | 65 72 73 20 69 73 20 73 |t regist|ers is s|
|00003410| 61 66 65 20 70 72 6f 76 | 69 64 65 64 20 69 74 73 |afe prov|ided its|
|00003420| 20 70 72 65 64 69 63 61 | 74 65 20 72 65 6a 65 63 | predica|te rejec|
|00003430| 74 73 20 72 65 67 69 73 | 74 65 72 73 2e 0d 0d 20 |ts regis|ters... |
|00003440| 20 20 20 20 41 6e 20 6f | 70 65 72 61 6e 64 20 77 | An o|perand w|
|00003450| 68 6f 73 65 20 70 72 65 | 64 69 63 61 74 65 20 61 |hose pre|dicate a|
|00003460| 63 63 65 70 74 73 20 6f | 6e 6c 79 20 63 6f 6e 73 |ccepts o|nly cons|
|00003470| 74 61 6e 74 20 76 61 6c | 75 65 73 20 69 73 20 73 |tant val|ues is s|
|00003480| 61 66 65 0d 20 20 20 20 | 20 70 72 6f 76 69 64 65 |afe. | provide|
|00003490| 64 20 69 74 73 20 63 6f | 6e 73 74 72 61 69 6e 74 |d its co|nstraint|
|000034a0| 73 20 69 6e 63 6c 75 64 | 65 20 74 68 65 20 6c 65 |s includ|e the le|
|000034b0| 74 74 65 72 20 60 69 27 | 2e 20 20 49 66 20 61 6e |tter `i'|. If an|
|000034c0| 79 0d 20 20 20 20 20 70 | 6f 73 73 69 62 6c 65 20 |y. p|ossible |
|000034d0| 63 6f 6e 73 74 61 6e 74 | 20 76 61 6c 75 65 20 69 |constant| value i|
|000034e0| 73 20 61 63 63 65 70 74 | 65 64 2c 20 74 68 65 6e |s accept|ed, then|
|000034f0| 20 6e 6f 74 68 69 6e 67 | 20 6c 65 73 73 20 74 68 | nothing| less th|
|00003500| 61 6e 20 60 69 27 0d 20 | 20 20 20 20 77 69 6c 6c |an `i'. | will|
|00003510| 20 64 6f 3b 20 69 66 20 | 74 68 65 20 70 72 65 64 | do; if |the pred|
|00003520| 69 63 61 74 65 20 69 73 | 20 6d 6f 72 65 20 73 65 |icate is| more se|
|00003530| 6c 65 63 74 69 76 65 2c | 20 74 68 65 6e 20 74 68 |lective,| then th|
|00003540| 65 0d 20 20 20 20 20 63 | 6f 6e 73 74 72 61 69 6e |e. c|onstrain|
|00003550| 74 73 20 6d 61 79 20 61 | 6c 73 6f 20 62 65 20 6d |ts may a|lso be m|
|00003560| 6f 72 65 20 73 65 6c 65 | 63 74 69 76 65 2e 0d 0d |ore sele|ctive...|
|00003570| 20 20 20 2a 20 41 6e 79 | 20 6f 70 65 72 61 6e 64 | * Any| operand|
|00003580| 20 65 78 70 72 65 73 73 | 69 6f 6e 20 63 61 6e 20 | express|ion can |
|00003590| 62 65 20 72 65 6c 6f 61 | 64 65 64 20 62 79 20 63 |be reloa|ded by c|
|000035a0| 6f 70 79 69 6e 67 20 69 | 74 20 69 6e 74 6f 20 61 |opying i|t into a|
|000035b0| 0d 20 20 20 20 20 72 65 | 67 69 73 74 65 72 2e 20 |. re|gister. |
|000035c0| 20 53 6f 20 69 66 20 61 | 6e 20 6f 70 65 72 61 6e | So if a|n operan|
|000035d0| 64 27 73 20 63 6f 6e 73 | 74 72 61 69 6e 74 73 20 |d's cons|traints |
|000035e0| 61 6c 6c 6f 77 20 73 6f | 6d 65 20 6b 69 6e 64 20 |allow so|me kind |
|000035f0| 6f 66 0d 20 20 20 20 20 | 72 65 67 69 73 74 65 72 |of. |register|
|00003600| 2c 20 69 74 20 69 73 20 | 63 65 72 74 61 69 6e 20 |, it is |certain |
|00003610| 74 6f 20 62 65 20 73 61 | 66 65 2e 20 20 49 74 20 |to be sa|fe. It |
|00003620| 6e 65 65 64 20 6e 6f 74 | 20 70 65 72 6d 69 74 20 |need not| permit |
|00003630| 61 6c 6c 0d 20 20 20 20 | 20 63 6c 61 73 73 65 73 |all. | classes|
|00003640| 20 6f 66 20 72 65 67 69 | 73 74 65 72 73 3b 20 74 | of regi|sters; t|
|00003650| 68 65 20 63 6f 6d 70 69 | 6c 65 72 20 6b 6e 6f 77 |he compi|ler know|
|00003660| 73 20 68 6f 77 20 74 6f | 20 63 6f 70 79 20 61 20 |s how to| copy a |
|00003670| 72 65 67 69 73 74 65 72 | 0d 20 20 20 20 20 69 6e |register|. in|
|00003680| 74 6f 20 61 6e 6f 74 68 | 65 72 20 72 65 67 69 73 |to anoth|er regis|
|00003690| 74 65 72 20 6f 66 20 74 | 68 65 20 70 72 6f 70 65 |ter of t|he prope|
|000036a0| 72 20 63 6c 61 73 73 20 | 69 6e 20 6f 72 64 65 72 |r class |in order|
|000036b0| 20 74 6f 20 6d 61 6b 65 | 20 61 6e 0d 20 20 20 20 | to make| an. |
|000036c0| 20 69 6e 73 74 72 75 63 | 74 69 6f 6e 20 76 61 6c | instruc|tion val|
|000036d0| 69 64 2e 0d 0d 20 20 20 | 2a 20 41 20 6e 6f 6e 6f |id... |* A nono|
|000036e0| 66 66 73 65 74 74 61 62 | 6c 65 20 6d 65 6d 6f 72 |ffsettab|le memor|
|000036f0| 79 20 72 65 66 65 72 65 | 6e 63 65 20 63 61 6e 20 |y refere|nce can |
|00003700| 62 65 20 72 65 6c 6f 61 | 64 65 64 20 62 79 20 63 |be reloa|ded by c|
|00003710| 6f 70 79 69 6e 67 20 74 | 68 65 0d 20 20 20 20 20 |opying t|he. |
|00003720| 61 64 64 72 65 73 73 20 | 69 6e 74 6f 20 61 20 72 |address |into a r|
|00003730| 65 67 69 73 74 65 72 2e | 20 20 53 6f 20 69 66 20 |egister.| So if |
|00003740| 74 68 65 20 63 6f 6e 73 | 74 72 61 69 6e 74 20 75 |the cons|traint u|
|00003750| 73 65 73 20 74 68 65 20 | 6c 65 74 74 65 72 0d 20 |ses the |letter. |
|00003760| 20 20 20 20 60 6f 27 2c | 20 61 6c 6c 20 6d 65 6d | `o',| all mem|
|00003770| 6f 72 79 20 72 65 66 65 | 72 65 6e 63 65 73 20 61 |ory refe|rences a|
|00003780| 72 65 20 74 61 6b 65 6e | 20 63 61 72 65 20 6f 66 |re taken| care of|
|00003790| 2e 0d 0d 20 20 20 2a 20 | 41 20 63 6f 6e 73 74 61 |... * |A consta|
|000037a0| 6e 74 20 6f 70 65 72 61 | 6e 64 20 63 61 6e 20 62 |nt opera|nd can b|
|000037b0| 65 20 72 65 6c 6f 61 64 | 65 64 20 62 79 20 61 6c |e reload|ed by al|
|000037c0| 6c 6f 63 61 74 69 6e 67 | 20 73 70 61 63 65 20 69 |locating| space i|
|000037d0| 6e 20 6d 65 6d 6f 72 79 | 0d 20 20 20 20 20 74 6f |n memory|. to|
|000037e0| 20 68 6f 6c 64 20 69 74 | 20 61 73 20 70 72 65 69 | hold it| as prei|
|000037f0| 6e 69 74 69 61 6c 69 7a | 65 64 20 64 61 74 61 2e |nitializ|ed data.|
|00003800| 20 20 54 68 65 6e 20 74 | 68 65 20 6d 65 6d 6f 72 | Then t|he memor|
|00003810| 79 20 72 65 66 65 72 65 | 6e 63 65 0d 20 20 20 20 |y refere|nce. |
|00003820| 20 63 61 6e 20 62 65 20 | 75 73 65 64 20 69 6e 20 | can be |used in |
|00003830| 70 6c 61 63 65 20 6f 66 | 20 74 68 65 20 63 6f 6e |place of| the con|
|00003840| 73 74 61 6e 74 2e 20 20 | 53 6f 20 69 66 20 74 68 |stant. |So if th|
|00003850| 65 20 63 6f 6e 73 74 72 | 61 69 6e 74 20 75 73 65 |e constr|aint use|
|00003860| 73 0d 20 20 20 20 20 74 | 68 65 20 6c 65 74 74 65 |s. t|he lette|
|00003870| 72 73 20 60 6f 27 20 6f | 72 20 60 6d 27 2c 20 63 |rs `o' o|r `m', c|
|00003880| 6f 6e 73 74 61 6e 74 20 | 6f 70 65 72 61 6e 64 73 |onstant |operands|
|00003890| 20 61 72 65 20 6e 6f 74 | 20 61 20 70 72 6f 62 6c | are not| a probl|
|000038a0| 65 6d 2e 0d 0d 49 66 20 | 74 68 65 20 6f 70 65 72 |em...If |the oper|
|000038b0| 61 6e 64 27 73 20 70 72 | 65 64 69 63 61 74 65 20 |and's pr|edicate |
|000038c0| 63 61 6e 20 72 65 63 6f | 67 6e 69 7a 65 20 72 65 |can reco|gnize re|
|000038d0| 67 69 73 74 65 72 73 2c | 20 62 75 74 20 74 68 65 |gisters,| but the|
|000038e0| 0d 63 6f 6e 73 74 72 61 | 69 6e 74 20 64 6f 65 73 |.constra|int does|
|000038f0| 20 6e 6f 74 20 70 65 72 | 6d 69 74 20 74 68 65 6d | not per|mit them|
|00003900| 2c 20 69 74 20 63 61 6e | 20 6d 61 6b 65 20 74 68 |, it can| make th|
|00003910| 65 20 63 6f 6d 70 69 6c | 65 72 20 63 72 61 73 68 |e compil|er crash|
|00003920| 2e 20 0d 57 68 65 6e 20 | 74 68 69 73 20 6f 70 65 |. .When |this ope|
|00003930| 72 61 6e 64 20 68 61 70 | 70 65 6e 73 20 74 6f 20 |rand hap|pens to |
|00003940| 62 65 20 61 20 72 65 67 | 69 73 74 65 72 2c 20 74 |be a reg|ister, t|
|00003950| 68 65 20 72 65 6c 6f 61 | 64 20 70 61 73 73 20 77 |he reloa|d pass w|
|00003960| 69 6c 6c 20 62 65 0d 73 | 74 79 6d 69 65 64 2c 20 |ill be.s|tymied, |
|00003970| 62 65 63 61 75 73 65 20 | 69 74 20 64 6f 65 73 20 |because |it does |
|00003980| 6e 6f 74 20 6b 6e 6f 77 | 20 68 6f 77 20 74 6f 20 |not know| how to |
|00003990| 63 6f 70 79 20 61 20 72 | 65 67 69 73 74 65 72 20 |copy a r|egister |
|000039a0| 74 65 6d 70 6f 72 61 72 | 69 6c 79 0d 69 6e 74 6f |temporar|ily.into|
|000039b0| 20 6d 65 6d 6f 72 79 2e | 0d 0d 0d 1f 0d 46 69 6c | memory.|.....Fil|
|000039c0| 65 3a 20 67 63 63 2e 69 | 6e 66 6f 2c 20 20 4e 6f |e: gcc.i|nfo, No|
|000039d0| 64 65 3a 20 4d 75 6c 74 | 69 2d 41 6c 74 65 72 6e |de: Mult|i-Altern|
|000039e0| 61 74 69 76 65 2c 20 20 | 4e 65 78 74 3a 20 43 6c |ative, |Next: Cl|
|000039f0| 61 73 73 20 50 72 65 66 | 65 72 65 6e 63 65 73 2c |ass Pref|erences,|
|00003a00| 20 20 50 72 65 76 3a 20 | 53 69 6d 70 6c 65 20 43 | Prev: |Simple C|
|00003a10| 6f 6e 73 74 72 61 69 6e | 74 73 2c 20 20 55 70 3a |onstrain|ts, Up:|
|00003a20| 20 43 6f 6e 73 74 72 61 | 69 6e 74 73 0d 0d 4d 75 | Constra|ints..Mu|
|00003a30| 6c 74 69 70 6c 65 20 41 | 6c 74 65 72 6e 61 74 69 |ltiple A|lternati|
|00003a40| 76 65 20 43 6f 6e 73 74 | 72 61 69 6e 74 73 0d 2d |ve Const|raints.-|
|00003a50| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00003a60| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 0d |--------|-------.|
|00003a70| 0d 53 6f 6d 65 74 69 6d | 65 73 20 61 20 73 69 6e |.Sometim|es a sin|
|00003a80| 67 6c 65 20 69 6e 73 74 | 72 75 63 74 69 6f 6e 20 |gle inst|ruction |
|00003a90| 68 61 73 20 6d 75 6c 74 | 69 70 6c 65 20 61 6c 74 |has mult|iple alt|
|00003aa0| 65 72 6e 61 74 69 76 65 | 20 73 65 74 73 20 6f 66 |ernative| sets of|
|00003ab0| 0d 70 6f 73 73 69 62 6c | 65 20 6f 70 65 72 61 6e |.possibl|e operan|
|00003ac0| 64 73 2e 20 20 46 6f 72 | 20 65 78 61 6d 70 6c 65 |ds. For| example|
|00003ad0| 2c 20 6f 6e 20 74 68 65 | 20 36 38 30 30 30 2c 20 |, on the| 68000, |
|00003ae0| 61 20 6c 6f 67 69 63 61 | 6c 2d 6f 72 0d 69 6e 73 |a logica|l-or.ins|
|00003af0| 74 72 75 63 74 69 6f 6e | 20 63 61 6e 20 63 6f 6d |truction| can com|
|00003b00| 62 69 6e 65 20 72 65 67 | 69 73 74 65 72 20 6f 72 |bine reg|ister or|
|00003b10| 20 61 6e 20 69 6d 6d 65 | 64 69 61 74 65 20 76 61 | an imme|diate va|
|00003b20| 6c 75 65 20 69 6e 74 6f | 20 6d 65 6d 6f 72 79 2c |lue into| memory,|
|00003b30| 0d 6f 72 20 69 74 20 63 | 61 6e 20 63 6f 6d 62 69 |.or it c|an combi|
|00003b40| 6e 65 20 61 6e 79 20 6b | 69 6e 64 20 6f 66 20 6f |ne any k|ind of o|
|00003b50| 70 65 72 61 6e 64 20 69 | 6e 74 6f 20 61 20 72 65 |perand i|nto a re|
|00003b60| 67 69 73 74 65 72 3b 20 | 62 75 74 20 69 74 20 63 |gister; |but it c|
|00003b70| 61 6e 6e 6f 74 0d 63 6f | 6d 62 69 6e 65 20 6f 6e |annot.co|mbine on|
|00003b80| 65 20 6d 65 6d 6f 72 79 | 20 6c 6f 63 61 74 69 6f |e memory| locatio|
|00003b90| 6e 20 69 6e 74 6f 20 61 | 6e 6f 74 68 65 72 2e 0d |n into a|nother..|
|00003ba0| 0d 54 68 65 73 65 20 63 | 6f 6e 73 74 72 61 69 6e |.These c|onstrain|
|00003bb0| 74 73 20 61 72 65 20 72 | 65 70 72 65 73 65 6e 74 |ts are r|epresent|
|00003bc0| 65 64 20 61 73 20 6d 75 | 6c 74 69 70 6c 65 20 61 |ed as mu|ltiple a|
|00003bd0| 6c 74 65 72 6e 61 74 69 | 76 65 73 2e 20 20 41 6e |lternati|ves. An|
|00003be0| 0d 61 6c 74 65 72 6e 61 | 74 69 76 65 20 63 61 6e |.alterna|tive can|
|00003bf0| 20 62 65 20 64 65 73 63 | 72 69 62 65 64 20 62 79 | be desc|ribed by|
|00003c00| 20 61 20 73 65 72 69 65 | 73 20 6f 66 20 6c 65 74 | a serie|s of let|
|00003c10| 74 65 72 73 20 66 6f 72 | 20 65 61 63 68 20 6f 70 |ters for| each op|
|00003c20| 65 72 61 6e 64 2e 0d 54 | 68 65 20 6f 76 65 72 61 |erand..T|he overa|
|00003c30| 6c 6c 20 63 6f 6e 73 74 | 72 61 69 6e 74 20 66 6f |ll const|raint fo|
|00003c40| 72 20 61 6e 20 6f 70 65 | 72 61 6e 64 20 69 73 20 |r an ope|rand is |
|00003c50| 6d 61 64 65 20 66 72 6f | 6d 20 74 68 65 20 6c 65 |made fro|m the le|
|00003c60| 74 74 65 72 73 20 66 6f | 72 0d 74 68 69 73 20 6f |tters fo|r.this o|
|00003c70| 70 65 72 61 6e 64 20 66 | 72 6f 6d 20 74 68 65 20 |perand f|rom the |
|00003c80| 66 69 72 73 74 20 61 6c | 74 65 72 6e 61 74 69 76 |first al|ternativ|
|00003c90| 65 2c 20 61 20 63 6f 6d | 6d 61 2c 20 74 68 65 20 |e, a com|ma, the |
|00003ca0| 6c 65 74 74 65 72 73 20 | 66 6f 72 0d 74 68 69 73 |letters |for.this|
|00003cb0| 20 6f 70 65 72 61 6e 64 | 20 66 72 6f 6d 20 74 68 | operand| from th|
|00003cc0| 65 20 73 65 63 6f 6e 64 | 20 61 6c 74 65 72 6e 61 |e second| alterna|
|00003cd0| 74 69 76 65 2c 20 61 20 | 63 6f 6d 6d 61 2c 20 61 |tive, a |comma, a|
|00003ce0| 6e 64 20 73 6f 20 6f 6e | 20 75 6e 74 69 6c 0d 74 |nd so on| until.t|
|00003cf0| 68 65 20 6c 61 73 74 20 | 61 6c 74 65 72 6e 61 74 |he last |alternat|
|00003d00| 69 76 65 2e 20 20 48 65 | 72 65 20 69 73 20 68 6f |ive. He|re is ho|
|00003d10| 77 20 69 74 20 69 73 20 | 64 6f 6e 65 20 66 6f 72 |w it is |done for|
|00003d20| 20 66 75 6c 6c 77 6f 72 | 64 20 6c 6f 67 69 63 61 | fullwor|d logica|
|00003d30| 6c 2d 6f 72 0d 6f 6e 20 | 74 68 65 20 36 38 30 30 |l-or.on |the 6800|
|00003d40| 30 3a 0d 0d 20 20 20 20 | 20 28 64 65 66 69 6e 65 |0:.. | (define|
|00003d50| 5f 69 6e 73 6e 20 22 69 | 6f 72 73 69 33 22 0d 20 |_insn "i|orsi3". |
|00003d60| 20 20 20 20 20 20 5b 28 | 73 65 74 20 28 6d 61 74 | [(|set (mat|
|00003d70| 63 68 5f 6f 70 65 72 61 | 6e 64 3a 53 49 20 30 20 |ch_opera|nd:SI 0 |
|00003d80| 22 67 65 6e 65 72 61 6c | 5f 6f 70 65 72 61 6e 64 |"general|_operand|
|00003d90| 22 20 22 3d 6d 2c 64 22 | 29 0d 20 20 20 20 20 20 |" "=m,d"|). |
|00003da0| 20 20 20 20 20 20 20 28 | 69 6f 72 3a 53 49 20 28 | (|ior:SI (|
|00003db0| 6d 61 74 63 68 5f 6f 70 | 65 72 61 6e 64 3a 53 49 |match_op|erand:SI|
|00003dc0| 20 31 20 22 67 65 6e 65 | 72 61 6c 5f 6f 70 65 72 | 1 "gene|ral_oper|
|00003dd0| 61 6e 64 22 20 22 25 30 | 2c 30 22 29 0d 20 20 20 |and" "%0|,0"). |
|00003de0| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|00003df0| 20 20 28 6d 61 74 63 68 | 5f 6f 70 65 72 61 6e 64 | (match|_operand|
|00003e00| 3a 53 49 20 32 20 22 67 | 65 6e 65 72 61 6c 5f 6f |:SI 2 "g|eneral_o|
|00003e10| 70 65 72 61 6e 64 22 20 | 22 64 4b 73 2c 64 6d 4b |perand" |"dKs,dmK|
|00003e20| 73 22 29 29 29 5d 0d 20 | 20 20 20 20 20 20 2e 2e |s")))]. | ..|
|00003e30| 2e 29 0d 0d 54 68 65 20 | 66 69 72 73 74 20 61 6c |.)..The |first al|
|00003e40| 74 65 72 6e 61 74 69 76 | 65 20 68 61 73 20 60 6d |ternativ|e has `m|
|00003e50| 27 20 28 6d 65 6d 6f 72 | 79 29 20 66 6f 72 20 6f |' (memor|y) for o|
|00003e60| 70 65 72 61 6e 64 20 30 | 2c 20 60 30 27 20 66 6f |perand 0|, `0' fo|
|00003e70| 72 20 6f 70 65 72 61 6e | 64 0d 31 20 28 6d 65 61 |r operan|d.1 (mea|
|00003e80| 6e 69 6e 67 20 69 74 20 | 6d 75 73 74 20 6d 61 74 |ning it |must mat|
|00003e90| 63 68 20 6f 70 65 72 61 | 6e 64 20 30 29 2c 20 61 |ch opera|nd 0), a|
|00003ea0| 6e 64 20 60 64 4b 73 27 | 20 66 6f 72 20 6f 70 65 |nd `dKs'| for ope|
|00003eb0| 72 61 6e 64 20 32 2e 20 | 20 54 68 65 0d 73 65 63 |rand 2. | The.sec|
|00003ec0| 6f 6e 64 20 61 6c 74 65 | 72 6e 61 74 69 76 65 20 |ond alte|rnative |
|00003ed0| 68 61 73 20 60 64 27 20 | 28 64 61 74 61 20 72 65 |has `d' |(data re|
|00003ee0| 67 69 73 74 65 72 29 20 | 66 6f 72 20 6f 70 65 72 |gister) |for oper|
|00003ef0| 61 6e 64 20 30 2c 20 60 | 30 27 20 66 6f 72 0d 6f |and 0, `|0' for.o|
|00003f00| 70 65 72 61 6e 64 20 31 | 2c 20 61 6e 64 20 60 64 |perand 1|, and `d|
|00003f10| 6d 4b 73 27 20 66 6f 72 | 20 6f 70 65 72 61 6e 64 |mKs' for| operand|
|00003f20| 20 32 2e 20 20 54 68 65 | 20 60 3d 27 20 61 6e 64 | 2. The| `=' and|
|00003f30| 20 60 25 27 20 69 6e 20 | 74 68 65 0d 63 6f 6e 73 | `%' in |the.cons|
|00003f40| 74 72 61 69 6e 74 73 20 | 61 70 70 6c 79 20 74 6f |traints |apply to|
|00003f50| 20 61 6c 6c 20 74 68 65 | 20 61 6c 74 65 72 6e 61 | all the| alterna|
|00003f60| 74 69 76 65 73 3b 20 74 | 68 65 69 72 20 6d 65 61 |tives; t|heir mea|
|00003f70| 6e 69 6e 67 20 69 73 20 | 65 78 70 6c 61 69 6e 65 |ning is |explaine|
|00003f80| 64 0d 69 6e 20 74 68 65 | 20 6e 65 78 74 20 73 65 |d.in the| next se|
|00003f90| 63 74 69 6f 6e 2e 0d 0d | 49 66 20 61 6c 6c 20 74 |ction...|If all t|
|00003fa0| 68 65 20 6f 70 65 72 61 | 6e 64 73 20 66 69 74 20 |he opera|nds fit |
|00003fb0| 61 6e 79 20 6f 6e 65 20 | 61 6c 74 65 72 6e 61 74 |any one |alternat|
|00003fc0| 69 76 65 2c 20 74 68 65 | 20 69 6e 73 74 72 75 63 |ive, the| instruc|
|00003fd0| 74 69 6f 6e 20 69 73 20 | 76 61 6c 69 64 2e 0d 4f |tion is |valid..O|
|00003fe0| 74 68 65 72 77 69 73 65 | 2c 20 66 6f 72 20 65 61 |therwise|, for ea|
|00003ff0| 63 68 20 61 6c 74 65 72 | 6e 61 74 69 76 65 2c 20 |ch alter|native, |
|00004000| 74 68 65 20 63 6f 6d 70 | 69 6c 65 72 20 63 6f 75 |the comp|iler cou|
|00004010| 6e 74 73 20 68 6f 77 20 | 6d 61 6e 79 0d 69 6e 73 |nts how |many.ins|
|00004020| 74 72 75 63 74 69 6f 6e | 73 20 6d 75 73 74 20 62 |truction|s must b|
|00004030| 65 20 61 64 64 65 64 20 | 74 6f 20 63 6f 70 79 20 |e added |to copy |
|00004040| 74 68 65 20 6f 70 65 72 | 61 6e 64 73 20 73 6f 20 |the oper|ands so |
|00004050| 74 68 61 74 20 74 68 61 | 74 0d 61 6c 74 65 72 6e |that tha|t.altern|
|00004060| 61 74 69 76 65 20 61 70 | 70 6c 69 65 73 2e 20 20 |ative ap|plies. |
|00004070| 54 68 65 20 61 6c 74 65 | 72 6e 61 74 69 76 65 20 |The alte|rnative |
|00004080| 72 65 71 75 69 72 69 6e | 67 20 74 68 65 20 6c 65 |requirin|g the le|
|00004090| 61 73 74 20 63 6f 70 79 | 69 6e 67 20 69 73 0d 63 |ast copy|ing is.c|
|000040a0| 68 6f 73 65 6e 2e 20 20 | 49 66 20 74 77 6f 20 61 |hosen. |If two a|
|000040b0| 6c 74 65 72 6e 61 74 69 | 76 65 73 20 6e 65 65 64 |lternati|ves need|
|000040c0| 20 74 68 65 20 73 61 6d | 65 20 61 6d 6f 75 6e 74 | the sam|e amount|
|000040d0| 20 6f 66 20 63 6f 70 79 | 69 6e 67 2c 20 74 68 65 | of copy|ing, the|
|000040e0| 20 6f 6e 65 0d 74 68 61 | 74 20 63 6f 6d 65 73 20 | one.tha|t comes |
|000040f0| 66 69 72 73 74 20 69 73 | 20 63 68 6f 73 65 6e 2e |first is| chosen.|
|00004100| 20 20 54 68 65 73 65 20 | 63 68 6f 69 63 65 73 20 | These |choices |
|00004110| 63 61 6e 20 62 65 20 61 | 6c 74 65 72 65 64 20 77 |can be a|ltered w|
|00004120| 69 74 68 20 74 68 65 0d | 60 3f 27 20 61 6e 64 20 |ith the.|`?' and |
|00004130| 60 21 27 20 63 68 61 72 | 61 63 74 65 72 73 3a 0d |`!' char|acters:.|
|00004140| 0d 60 3f 27 0d 20 20 20 | 20 20 44 69 73 70 61 72 |.`?'. | Dispar|
|00004150| 61 67 65 20 73 6c 69 67 | 68 74 6c 79 20 74 68 65 |age slig|htly the|
|00004160| 20 61 6c 74 65 72 6e 61 | 74 69 76 65 20 74 68 61 | alterna|tive tha|
|00004170| 74 20 74 68 65 20 60 3f | 27 20 61 70 70 65 61 72 |t the `?|' appear|
|00004180| 73 20 69 6e 2c 20 61 73 | 20 61 0d 20 20 20 20 20 |s in, as| a. |
|00004190| 63 68 6f 69 63 65 20 77 | 68 65 6e 20 6e 6f 20 61 |choice w|hen no a|
|000041a0| 6c 74 65 72 6e 61 74 69 | 76 65 20 61 70 70 6c 69 |lternati|ve appli|
|000041b0| 65 73 20 65 78 61 63 74 | 6c 79 2e 20 20 54 68 65 |es exact|ly. The|
|000041c0| 20 63 6f 6d 70 69 6c 65 | 72 0d 20 20 20 20 20 72 | compile|r. r|
|000041d0| 65 67 61 72 64 73 20 74 | 68 69 73 20 61 6c 74 65 |egards t|his alte|
|000041e0| 72 6e 61 74 69 76 65 20 | 61 73 20 6f 6e 65 20 75 |rnative |as one u|
|000041f0| 6e 69 74 20 6d 6f 72 65 | 20 63 6f 73 74 6c 79 20 |nit more| costly |
|00004200| 66 6f 72 20 65 61 63 68 | 20 60 3f 27 0d 20 20 20 |for each| `?'. |
|00004210| 20 20 74 68 61 74 20 61 | 70 70 65 61 72 73 20 69 | that a|ppears i|
|00004220| 6e 20 69 74 2e 0d 0d 60 | 21 27 0d 20 20 20 20 20 |n it...`|!'. |
|00004230| 44 69 73 70 61 72 61 67 | 65 20 73 65 76 65 72 65 |Disparag|e severe|
|00004240| 6c 79 20 74 68 65 20 61 | 6c 74 65 72 6e 61 74 69 |ly the a|lternati|
|00004250| 76 65 20 74 68 61 74 20 | 74 68 65 20 60 21 27 20 |ve that |the `!' |
|00004260| 61 70 70 65 61 72 73 20 | 69 6e 2e 20 0d 20 20 20 |appears |in. . |
|00004270| 20 20 57 68 65 6e 20 6f | 70 65 72 61 6e 64 73 20 | When o|perands |
|00004280| 6d 75 73 74 20 62 65 20 | 63 6f 70 69 65 64 20 69 |must be |copied i|
|00004290| 6e 74 6f 20 72 65 67 69 | 73 74 65 72 73 2c 20 74 |nto regi|sters, t|
|000042a0| 68 65 20 63 6f 6d 70 69 | 6c 65 72 20 77 69 6c 6c |he compi|ler will|
|000042b0| 0d 20 20 20 20 20 6e 65 | 76 65 72 20 63 68 6f 6f |. ne|ver choo|
|000042c0| 73 65 20 74 68 69 73 20 | 61 6c 74 65 72 6e 61 74 |se this |alternat|
|000042d0| 69 76 65 20 61 73 20 74 | 68 65 20 6f 6e 65 20 74 |ive as t|he one t|
|000042e0| 6f 20 73 74 72 69 76 65 | 20 66 6f 72 2e 0d 0d 57 |o strive| for...W|
|000042f0| 68 65 6e 20 61 6e 20 69 | 6e 73 6e 20 70 61 74 74 |hen an i|nsn patt|
|00004300| 65 72 6e 20 68 61 73 20 | 6d 75 6c 74 69 70 6c 65 |ern has |multiple|
|00004310| 20 61 6c 74 65 72 6e 61 | 74 69 76 65 73 20 69 6e | alterna|tives in|
|00004320| 20 69 74 73 20 63 6f 6e | 73 74 72 61 69 6e 74 73 | its con|straints|
|00004330| 2c 0d 6f 66 74 65 6e 20 | 74 68 65 20 61 70 70 65 |,.often |the appe|
|00004340| 61 72 61 6e 63 65 20 6f | 66 20 74 68 65 20 61 73 |arance o|f the as|
|00004350| 73 65 6d 62 6c 65 72 20 | 63 6f 64 65 20 69 73 20 |sembler |code is |
|00004360| 64 65 74 65 72 6d 69 6e | 65 64 20 6d 6f 73 74 6c |determin|ed mostl|
|00004370| 79 20 62 79 0d 77 68 69 | 63 68 20 61 6c 74 65 72 |y by.whi|ch alter|
|00004380| 6e 61 74 69 76 65 20 77 | 61 73 20 6d 61 74 63 68 |native w|as match|
|00004390| 65 64 2e 20 20 57 68 65 | 6e 20 74 68 69 73 20 69 |ed. Whe|n this i|
|000043a0| 73 20 73 6f 2c 20 74 68 | 65 20 43 20 63 6f 64 65 |s so, th|e C code|
|000043b0| 20 66 6f 72 0d 77 72 69 | 74 69 6e 67 20 74 68 65 | for.wri|ting the|
|000043c0| 20 61 73 73 65 6d 62 6c | 65 72 20 63 6f 64 65 20 | assembl|er code |
|000043d0| 63 61 6e 20 75 73 65 20 | 74 68 65 20 76 61 72 69 |can use |the vari|
|000043e0| 61 62 6c 65 20 60 77 68 | 69 63 68 5f 61 6c 74 65 |able `wh|ich_alte|
|000043f0| 72 6e 61 74 69 76 65 27 | 2c 0d 77 68 69 63 68 20 |rnative'|,.which |
|00004400| 69 73 20 74 68 65 20 6f | 72 64 69 6e 61 6c 20 6e |is the o|rdinal n|
|00004410| 75 6d 62 65 72 20 6f 66 | 20 74 68 65 20 61 6c 74 |umber of| the alt|
|00004420| 65 72 6e 61 74 69 76 65 | 20 74 68 61 74 20 77 61 |ernative| that wa|
|00004430| 73 20 61 63 74 75 61 6c | 6c 79 0d 73 61 74 69 73 |s actual|ly.satis|
|00004440| 66 69 65 64 20 28 30 20 | 66 6f 72 20 74 68 65 20 |fied (0 |for the |
|00004450| 66 69 72 73 74 2c 20 31 | 20 66 6f 72 20 74 68 65 |first, 1| for the|
|00004460| 20 73 65 63 6f 6e 64 20 | 61 6c 74 65 72 6e 61 74 | second |alternat|
|00004470| 69 76 65 2c 20 65 74 63 | 2e 29 2e 20 20 46 6f 72 |ive, etc|.). For|
|00004480| 0d 65 78 61 6d 70 6c 65 | 3a 0d 0d 20 20 20 20 20 |.example|:.. |
|00004490| 28 64 65 66 69 6e 65 5f | 69 6e 73 6e 20 22 22 0d |(define_|insn "".|
|000044a0| 20 20 20 20 20 20 20 5b | 28 73 65 74 20 28 6d 61 | [|(set (ma|
|000044b0| 74 63 68 5f 6f 70 65 72 | 61 6e 64 3a 53 49 20 30 |tch_oper|and:SI 0|
|000044c0| 20 22 67 65 6e 65 72 61 | 6c 5f 6f 70 65 72 61 6e | "genera|l_operan|
|000044d0| 64 22 20 22 72 2c 6d 22 | 29 0d 20 20 20 20 20 20 |d" "r,m"|). |
|000044e0| 20 20 20 20 20 20 20 28 | 63 6f 6e 73 74 5f 69 6e | (|const_in|
|000044f0| 74 20 30 29 29 5d 0d 20 | 20 20 20 20 20 20 22 22 |t 0))]. | ""|
|00004500| 0d 20 20 20 20 20 20 20 | 22 2a 0d 20 20 20 20 20 |. |"*. |
|00004510| 20 20 72 65 74 75 72 6e | 20 28 77 68 69 63 68 5f | return| (which_|
|00004520| 61 6c 74 65 72 6e 61 74 | 69 76 65 20 3d 3d 20 30 |alternat|ive == 0|
|00004530| 0d 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 |. | |
|00004540| 3f 20 5c 22 63 6c 72 72 | 65 67 20 25 30 5c 22 20 |? \"clrr|eg %0\" |
|00004550| 3a 20 5c 22 63 6c 72 6d | 65 6d 20 25 30 5c 22 29 |: \"clrm|em %0\")|
|00004560| 3b 0d 20 20 20 20 20 20 | 20 22 29 0d 0d 0d 1f 0d |;. | ").....|
|00004570| 46 69 6c 65 3a 20 67 63 | 63 2e 69 6e 66 6f 2c 20 |File: gc|c.info, |
|00004580| 20 4e 6f 64 65 3a 20 43 | 6c 61 73 73 20 50 72 65 | Node: C|lass Pre|
|00004590| 66 65 72 65 6e 63 65 73 | 2c 20 20 4e 65 78 74 3a |ferences|, Next:|
|000045a0| 20 4d 6f 64 69 66 69 65 | 72 73 2c 20 20 50 72 65 | Modifie|rs, Pre|
|000045b0| 76 3a 20 4d 75 6c 74 69 | 2d 41 6c 74 65 72 6e 61 |v: Multi|-Alterna|
|000045c0| 74 69 76 65 2c 20 20 55 | 70 3a 20 43 6f 6e 73 74 |tive, U|p: Const|
|000045d0| 72 61 69 6e 74 73 0d 0d | 52 65 67 69 73 74 65 72 |raints..|Register|
|000045e0| 20 43 6c 61 73 73 20 50 | 72 65 66 65 72 65 6e 63 | Class P|referenc|
|000045f0| 65 73 0d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |es.-----|--------|
|00004600| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 0d 0d 54 |--------|-----..T|
|00004610| 68 65 20 6f 70 65 72 61 | 6e 64 20 63 6f 6e 73 74 |he opera|nd const|
|00004620| 72 61 69 6e 74 73 20 68 | 61 76 65 20 61 6e 6f 74 |raints h|ave anot|
|00004630| 68 65 72 20 66 75 6e 63 | 74 69 6f 6e 3a 20 74 68 |her func|tion: th|
|00004640| 65 79 20 65 6e 61 62 6c | 65 20 74 68 65 0d 63 6f |ey enabl|e the.co|
|00004650| 6d 70 69 6c 65 72 20 74 | 6f 20 64 65 63 69 64 65 |mpiler t|o decide|
|00004660| 20 77 68 69 63 68 20 6b | 69 6e 64 20 6f 66 20 68 | which k|ind of h|
|00004670| 61 72 64 77 61 72 65 20 | 72 65 67 69 73 74 65 72 |ardware |register|
|00004680| 20 61 20 70 73 65 75 64 | 6f 20 72 65 67 69 73 74 | a pseud|o regist|
|00004690| 65 72 0d 69 73 20 62 65 | 73 74 20 61 6c 6c 6f 63 |er.is be|st alloc|
|000046a0| 61 74 65 64 20 74 6f 2e | 20 20 54 68 65 20 63 6f |ated to.| The co|
|000046b0| 6d 70 69 6c 65 72 20 65 | 78 61 6d 69 6e 65 73 20 |mpiler e|xamines |
|000046c0| 74 68 65 20 63 6f 6e 73 | 74 72 61 69 6e 74 73 20 |the cons|traints |
|000046d0| 74 68 61 74 0d 61 70 70 | 6c 79 20 74 6f 20 74 68 |that.app|ly to th|
|000046e0| 65 20 69 6e 73 6e 73 20 | 74 68 61 74 20 75 73 65 |e insns |that use|
|000046f0| 20 74 68 65 20 70 73 65 | 75 64 6f 20 72 65 67 69 | the pse|udo regi|
|00004700| 73 74 65 72 2c 20 6c 6f | 6f 6b 69 6e 67 20 66 6f |ster, lo|oking fo|
|00004710| 72 20 74 68 65 0d 6d 61 | 63 68 69 6e 65 2d 64 65 |r the.ma|chine-de|
|00004720| 70 65 6e 64 65 6e 74 20 | 6c 65 74 74 65 72 73 20 |pendent |letters |
|00004730| 73 75 63 68 20 61 73 20 | 60 64 27 20 61 6e 64 20 |such as |`d' and |
|00004740| 60 61 27 20 74 68 61 74 | 20 73 70 65 63 69 66 79 |`a' that| specify|
|00004750| 20 63 6c 61 73 73 65 73 | 20 6f 66 0d 72 65 67 69 | classes| of.regi|
|00004760| 73 74 65 72 73 2e 20 20 | 54 68 65 20 70 73 65 75 |sters. |The pseu|
|00004770| 64 6f 20 72 65 67 69 73 | 74 65 72 20 69 73 20 70 |do regis|ter is p|
|00004780| 75 74 20 69 6e 20 77 68 | 69 63 68 65 76 65 72 20 |ut in wh|ichever |
|00004790| 63 6c 61 73 73 20 67 65 | 74 73 20 74 68 65 0d 6d |class ge|ts the.m|
|000047a0| 6f 73 74 20 60 60 76 6f | 74 65 73 27 27 2e 20 20 |ost ``vo|tes''. |
|000047b0| 54 68 65 20 63 6f 6e 73 | 74 72 61 69 6e 74 20 6c |The cons|traint l|
|000047c0| 65 74 74 65 72 73 20 60 | 67 27 20 61 6e 64 20 60 |etters `|g' and `|
|000047d0| 72 27 20 61 6c 73 6f 20 | 76 6f 74 65 3a 20 74 68 |r' also |vote: th|
|000047e0| 65 79 0d 76 6f 74 65 20 | 69 6e 20 66 61 76 6f 72 |ey.vote |in favor|
|000047f0| 20 6f 66 20 61 20 67 65 | 6e 65 72 61 6c 20 72 65 | of a ge|neral re|
|00004800| 67 69 73 74 65 72 2e 20 | 20 54 68 65 20 6d 61 63 |gister. | The mac|
|00004810| 68 69 6e 65 20 64 65 73 | 63 72 69 70 74 69 6f 6e |hine des|cription|
|00004820| 20 73 61 79 73 0d 77 68 | 69 63 68 20 72 65 67 69 | says.wh|ich regi|
|00004830| 73 74 65 72 73 20 61 72 | 65 20 63 6f 6e 73 69 64 |sters ar|e consid|
|00004840| 65 72 65 64 20 67 65 6e | 65 72 61 6c 2e 0d 0d 4f |ered gen|eral...O|
|00004850| 66 20 63 6f 75 72 73 65 | 2c 20 6f 6e 20 73 6f 6d |f course|, on som|
|00004860| 65 20 6d 61 63 68 69 6e | 65 73 20 61 6c 6c 20 72 |e machin|es all r|
|00004870| 65 67 69 73 74 65 72 73 | 20 61 72 65 20 65 71 75 |egisters| are equ|
|00004880| 69 76 61 6c 65 6e 74 2c | 20 61 6e 64 20 6e 6f 0d |ivalent,| and no.|
|00004890| 72 65 67 69 73 74 65 72 | 20 63 6c 61 73 73 65 73 |register| classes|
|000048a0| 20 61 72 65 20 64 65 66 | 69 6e 65 64 2e 20 20 54 | are def|ined. T|
|000048b0| 68 65 6e 20 6e 6f 6e 65 | 20 6f 66 20 74 68 69 73 |hen none| of this|
|000048c0| 20 63 6f 6d 70 6c 65 78 | 69 74 79 20 69 73 0d 72 | complex|ity is.r|
|000048d0| 65 6c 65 76 61 6e 74 2e | 0d 0d 0d 1f 0d 46 69 6c |elevant.|.....Fil|
|000048e0| 65 3a 20 67 63 63 2e 69 | 6e 66 6f 2c 20 20 4e 6f |e: gcc.i|nfo, No|
|000048f0| 64 65 3a 20 4d 6f 64 69 | 66 69 65 72 73 2c 20 20 |de: Modi|fiers, |
|00004900| 4e 65 78 74 3a 20 4e 6f | 20 43 6f 6e 73 74 72 61 |Next: No| Constra|
|00004910| 69 6e 74 73 2c 20 20 50 | 72 65 76 3a 20 43 6c 61 |ints, P|rev: Cla|
|00004920| 73 73 20 50 72 65 66 65 | 72 65 6e 63 65 73 2c 20 |ss Prefe|rences, |
|00004930| 20 55 70 3a 20 43 6f 6e | 73 74 72 61 69 6e 74 73 | Up: Con|straints|
|00004940| 0d 0d 43 6f 6e 73 74 72 | 61 69 6e 74 20 4d 6f 64 |..Constr|aint Mod|
|00004950| 69 66 69 65 72 20 43 68 | 61 72 61 63 74 65 72 73 |ifier Ch|aracters|
|00004960| 0d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |.-------|--------|
|00004970| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 0d |--------|-------.|
|00004980| 0d 60 3d 27 0d 20 20 20 | 20 20 4d 65 61 6e 73 20 |.`='. | Means |
|00004990| 74 68 61 74 20 74 68 69 | 73 20 6f 70 65 72 61 6e |that thi|s operan|
|000049a0| 64 20 69 73 20 77 72 69 | 74 65 2d 6f 6e 6c 79 20 |d is wri|te-only |
|000049b0| 66 6f 72 20 74 68 69 73 | 20 69 6e 73 74 72 75 63 |for this| instruc|
|000049c0| 74 69 6f 6e 3a 20 74 68 | 65 0d 20 20 20 20 20 70 |tion: th|e. p|
|000049d0| 72 65 76 69 6f 75 73 20 | 76 61 6c 75 65 20 69 73 |revious |value is|
|000049e0| 20 64 69 73 63 61 72 64 | 65 64 20 61 6e 64 20 72 | discard|ed and r|
|000049f0| 65 70 6c 61 63 65 64 20 | 62 79 20 6f 75 74 70 75 |eplaced |by outpu|
|00004a00| 74 20 64 61 74 61 2e 0d | 0d 60 2b 27 0d 20 20 20 |t data..|.`+'. |
|00004a10| 20 20 4d 65 61 6e 73 20 | 74 68 61 74 20 74 68 69 | Means |that thi|
|00004a20| 73 20 6f 70 65 72 61 6e | 64 20 69 73 20 62 6f 74 |s operan|d is bot|
|00004a30| 68 20 72 65 61 64 20 61 | 6e 64 20 77 72 69 74 74 |h read a|nd writt|
|00004a40| 65 6e 20 62 79 20 74 68 | 65 0d 20 20 20 20 20 69 |en by th|e. i|
|00004a50| 6e 73 74 72 75 63 74 69 | 6f 6e 2e 0d 0d 20 20 20 |nstructi|on... |
|00004a60| 20 20 57 68 65 6e 20 74 | 68 65 20 63 6f 6d 70 69 | When t|he compi|
|00004a70| 6c 65 72 20 66 69 78 65 | 73 20 75 70 20 74 68 65 |ler fixe|s up the|
|00004a80| 20 6f 70 65 72 61 6e 64 | 73 20 74 6f 20 73 61 74 | operand|s to sat|
|00004a90| 69 73 66 79 20 74 68 65 | 0d 20 20 20 20 20 63 6f |isfy the|. co|
|00004aa0| 6e 73 74 72 61 69 6e 74 | 73 2c 20 69 74 20 6e 65 |nstraint|s, it ne|
|00004ab0| 65 64 73 20 74 6f 20 6b | 6e 6f 77 20 77 68 69 63 |eds to k|now whic|
|00004ac0| 68 20 6f 70 65 72 61 6e | 64 73 20 61 72 65 20 69 |h operan|ds are i|
|00004ad0| 6e 70 75 74 73 20 74 6f | 20 74 68 65 0d 20 20 20 |nputs to| the. |
|00004ae0| 20 20 69 6e 73 74 72 75 | 63 74 69 6f 6e 20 61 6e | instru|ction an|
|00004af0| 64 20 77 68 69 63 68 20 | 61 72 65 20 6f 75 74 70 |d which |are outp|
|00004b00| 75 74 73 20 66 72 6f 6d | 20 69 74 2e 20 20 60 3d |uts from| it. `=|
|00004b10| 27 20 69 64 65 6e 74 69 | 66 69 65 73 20 61 6e 0d |' identi|fies an.|
|00004b20| 20 20 20 20 20 6f 75 74 | 70 75 74 3b 20 60 2b 27 | out|put; `+'|
|00004b30| 20 69 64 65 6e 74 69 66 | 69 65 73 20 61 6e 20 6f | identif|ies an o|
|00004b40| 70 65 72 61 6e 64 20 74 | 68 61 74 20 69 73 20 62 |perand t|hat is b|
|00004b50| 6f 74 68 20 69 6e 70 75 | 74 20 61 6e 64 20 6f 75 |oth inpu|t and ou|
|00004b60| 74 70 75 74 3b 0d 20 20 | 20 20 20 61 6c 6c 20 6f |tput;. | all o|
|00004b70| 74 68 65 72 20 6f 70 65 | 72 61 6e 64 73 20 61 72 |ther ope|rands ar|
|00004b80| 65 20 61 73 73 75 6d 65 | 64 20 74 6f 20 62 65 20 |e assume|d to be |
|00004b90| 69 6e 70 75 74 20 6f 6e | 6c 79 2e 0d 0d 60 26 27 |input on|ly...`&'|
|00004ba0| 0d 20 20 20 20 20 4d 65 | 61 6e 73 20 28 69 6e 20 |. Me|ans (in |
|00004bb0| 61 20 70 61 72 74 69 63 | 75 6c 61 72 20 61 6c 74 |a partic|ular alt|
|00004bc0| 65 72 6e 61 74 69 76 65 | 29 20 74 68 61 74 20 74 |ernative|) that t|
|00004bd0| 68 69 73 20 6f 70 65 72 | 61 6e 64 20 69 73 20 77 |his oper|and is w|
|00004be0| 72 69 74 74 65 6e 0d 20 | 20 20 20 20 62 65 66 6f |ritten. | befo|
|00004bf0| 72 65 20 74 68 65 20 69 | 6e 73 74 72 75 63 74 69 |re the i|nstructi|
|00004c00| 6f 6e 20 69 73 20 66 69 | 6e 69 73 68 65 64 20 75 |on is fi|nished u|
|00004c10| 73 69 6e 67 20 74 68 65 | 20 69 6e 70 75 74 20 6f |sing the| input o|
|00004c20| 70 65 72 61 6e 64 73 2e | 20 0d 20 20 20 20 20 54 |perands.| . T|
|00004c30| 68 65 72 65 66 6f 72 65 | 2c 20 74 68 69 73 20 6f |herefore|, this o|
|00004c40| 70 65 72 61 6e 64 20 6d | 61 79 20 6e 6f 74 20 6c |perand m|ay not l|
|00004c50| 69 65 20 69 6e 20 61 20 | 72 65 67 69 73 74 65 72 |ie in a |register|
|00004c60| 20 74 68 61 74 20 69 73 | 20 75 73 65 64 0d 20 20 | that is| used. |
|00004c70| 20 20 20 61 73 20 61 6e | 20 69 6e 70 75 74 20 6f | as an| input o|
|00004c80| 70 65 72 61 6e 64 20 6f | 72 20 61 73 20 70 61 72 |perand o|r as par|
|00004c90| 74 20 6f 66 20 61 6e 79 | 20 6d 65 6d 6f 72 79 20 |t of any| memory |
|00004ca0| 61 64 64 72 65 73 73 2e | 0d 0d 20 20 20 20 20 60 |address.|.. `|
|00004cb0| 26 27 20 61 70 70 6c 69 | 65 73 20 6f 6e 6c 79 20 |&' appli|es only |
|00004cc0| 74 6f 20 74 68 65 20 61 | 6c 74 65 72 6e 61 74 69 |to the a|lternati|
|00004cd0| 76 65 20 69 6e 20 77 68 | 69 63 68 20 69 74 20 69 |ve in wh|ich it i|
|00004ce0| 73 20 77 72 69 74 74 65 | 6e 2e 20 20 49 6e 0d 20 |s writte|n. In. |
|00004cf0| 20 20 20 20 63 6f 6e 73 | 74 72 61 69 6e 74 73 20 | cons|traints |
|00004d00| 77 69 74 68 20 6d 75 6c | 74 69 70 6c 65 20 61 6c |with mul|tiple al|
|00004d10| 74 65 72 6e 61 74 69 76 | 65 73 2c 20 73 6f 6d 65 |ternativ|es, some|
|00004d20| 74 69 6d 65 73 20 6f 6e | 65 0d 20 20 20 20 20 61 |times on|e. a|
|00004d30| 6c 74 65 72 6e 61 74 69 | 76 65 20 72 65 71 75 69 |lternati|ve requi|
|00004d40| 72 65 73 20 60 26 27 20 | 77 68 69 6c 65 20 6f 74 |res `&' |while ot|
|00004d50| 68 65 72 73 20 64 6f 20 | 6e 6f 74 2e 20 20 53 65 |hers do |not. Se|
|00004d60| 65 2c 20 66 6f 72 20 65 | 78 61 6d 70 6c 65 2c 0d |e, for e|xample,.|
|00004d70| 20 20 20 20 20 74 68 65 | 20 60 6d 6f 76 64 66 27 | the| `movdf'|
|00004d80| 20 69 6e 73 6e 20 6f 66 | 20 74 68 65 20 36 38 30 | insn of| the 680|
|00004d90| 30 30 2e 0d 0d 20 20 20 | 20 20 60 26 27 20 64 6f |00... | `&' do|
|00004da0| 65 73 20 6e 6f 74 20 6f | 62 76 69 61 74 65 20 74 |es not o|bviate t|
|00004db0| 68 65 20 6e 65 65 64 20 | 74 6f 20 77 72 69 74 65 |he need |to write|
|00004dc0| 20 60 3d 27 2e 0d 0d 60 | 25 27 0d 20 20 20 20 20 | `='...`|%'. |
|00004dd0| 44 65 63 6c 61 72 65 73 | 20 74 68 65 20 69 6e 73 |Declares| the ins|
|00004de0| 74 72 75 63 74 69 6f 6e | 20 74 6f 20 62 65 20 63 |truction| to be c|
|00004df0| 6f 6d 6d 75 74 61 74 69 | 76 65 20 66 6f 72 20 74 |ommutati|ve for t|
|00004e00| 68 69 73 20 6f 70 65 72 | 61 6e 64 20 61 6e 64 0d |his oper|and and.|
|00004e10| 20 20 20 20 20 74 68 65 | 20 66 6f 6c 6c 6f 77 69 | the| followi|
|00004e20| 6e 67 20 6f 70 65 72 61 | 6e 64 2e 20 20 54 68 69 |ng opera|nd. Thi|
|00004e30| 73 20 6d 65 61 6e 73 20 | 74 68 61 74 20 74 68 65 |s means |that the|
|00004e40| 20 63 6f 6d 70 69 6c 65 | 72 20 6d 61 79 0d 20 20 | compile|r may. |
|00004e50| 20 20 20 69 6e 74 65 72 | 63 68 61 6e 67 65 20 74 | inter|change t|
|00004e60| 68 65 20 74 77 6f 20 6f | 70 65 72 61 6e 64 73 20 |he two o|perands |
|00004e70| 69 66 20 74 68 61 74 20 | 69 73 20 74 68 65 20 63 |if that |is the c|
|00004e80| 68 65 61 70 65 73 74 20 | 77 61 79 20 74 6f 20 6d |heapest |way to m|
|00004e90| 61 6b 65 0d 20 20 20 20 | 20 61 6c 6c 20 6f 70 65 |ake. | all ope|
|00004ea0| 72 61 6e 64 73 20 66 69 | 74 20 74 68 65 20 63 6f |rands fi|t the co|
|00004eb0| 6e 73 74 72 61 69 6e 74 | 73 2e 20 20 54 68 69 73 |nstraint|s. This|
|00004ec0| 20 69 73 20 6f 66 74 65 | 6e 20 75 73 65 64 20 69 | is ofte|n used i|
|00004ed0| 6e 0d 20 20 20 20 20 70 | 61 74 74 65 72 6e 73 20 |n. p|atterns |
|00004ee0| 66 6f 72 20 61 64 64 69 | 74 69 6f 6e 20 69 6e 73 |for addi|tion ins|
|00004ef0| 74 72 75 63 74 69 6f 6e | 73 20 74 68 61 74 20 72 |truction|s that r|
|00004f00| 65 61 6c 6c 79 20 68 61 | 76 65 20 6f 6e 6c 79 20 |eally ha|ve only |
|00004f10| 74 77 6f 0d 20 20 20 20 | 20 6f 70 65 72 61 6e 64 |two. | operand|
|00004f20| 73 3a 20 74 68 65 20 72 | 65 73 75 6c 74 20 6d 75 |s: the r|esult mu|
|00004f30| 73 74 20 67 6f 20 69 6e | 20 6f 6e 65 20 6f 66 20 |st go in| one of |
|00004f40| 74 68 65 20 61 72 67 75 | 6d 65 6e 74 73 2e 20 20 |the argu|ments. |
|00004f50| 48 65 72 65 20 66 6f 72 | 0d 20 20 20 20 20 65 78 |Here for|. ex|
|00004f60| 61 6d 70 6c 65 2c 20 69 | 73 20 68 6f 77 20 74 68 |ample, i|s how th|
|00004f70| 65 20 36 38 30 30 30 20 | 68 61 6c 66 77 6f 72 64 |e 68000 |halfword|
|00004f80| 2d 61 64 64 20 69 6e 73 | 74 72 75 63 74 69 6f 6e |-add ins|truction|
|00004f90| 20 69 73 20 64 65 66 69 | 6e 65 64 3a 0d 0d 20 20 | is defi|ned:.. |
|00004fa0| 20 20 20 20 20 20 20 20 | 28 64 65 66 69 6e 65 5f | |(define_|
|00004fb0| 69 6e 73 6e 20 22 61 64 | 64 68 69 33 22 0d 20 20 |insn "ad|dhi3". |
|00004fc0| 20 20 20 20 20 20 20 20 | 20 20 5b 28 73 65 74 20 | | [(set |
|00004fd0| 28 6d 61 74 63 68 5f 6f | 70 65 72 61 6e 64 3a 48 |(match_o|perand:H|
|00004fe0| 49 20 30 20 22 67 65 6e | 65 72 61 6c 5f 6f 70 65 |I 0 "gen|eral_ope|
|00004ff0| 72 61 6e 64 22 20 22 3d | 6d 2c 72 22 29 0d 20 20 |rand" "=|m,r"). |
|00005000| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 28 70 6c | | (pl|
|00005010| 75 73 3a 48 49 20 28 6d | 61 74 63 68 5f 6f 70 65 |us:HI (m|atch_ope|
|00005020| 72 61 6e 64 3a 48 49 20 | 31 20 22 67 65 6e 65 72 |rand:HI |1 "gener|
|00005030| 61 6c 5f 6f 70 65 72 61 | 6e 64 22 20 22 25 30 2c |al_opera|nd" "%0,|
|00005040| 30 22 29 0d 20 20 20 20 | 20 20 20 20 20 20 20 20 |0"). | |
|00005050| 20 20 20 20 20 20 20 20 | 20 20 20 20 28 6d 61 74 | | (mat|
|00005060| 63 68 5f 6f 70 65 72 61 | 6e 64 3a 48 49 20 32 20 |ch_opera|nd:HI 2 |
|00005070| 22 67 65 6e 65 72 61 6c | 5f 6f 70 65 72 61 6e 64 |"general|_operand|
|00005080| 22 20 22 64 69 2c 67 22 | 29 29 29 5d 0d 20 20 20 |" "di,g"|)))]. |
|00005090| 20 20 20 20 20 20 20 20 | 20 2e 2e 2e 29 0d 0d 20 | | ...).. |
|000050a0| 20 20 20 20 4e 6f 74 65 | 20 74 68 61 74 20 69 6e | Note| that in|
|000050b0| 20 70 72 65 76 69 6f 75 | 73 20 76 65 72 73 69 6f | previou|s versio|
|000050c0| 6e 73 20 6f 66 20 47 4e | 55 20 43 43 20 74 68 65 |ns of GN|U CC the|
|000050d0| 20 60 25 27 20 63 6f 6e | 73 74 72 61 69 6e 74 0d | `%' con|straint.|
|000050e0| 20 20 20 20 20 6d 6f 64 | 69 66 69 65 72 20 61 6c | mod|ifier al|
|000050f0| 77 61 79 73 20 61 70 70 | 6c 69 65 64 20 74 6f 20 |ways app|lied to |
|00005100| 6f 70 65 72 61 6e 64 73 | 20 31 20 61 6e 64 20 32 |operands| 1 and 2|
|00005110| 20 72 65 67 61 72 64 6c | 65 73 73 20 6f 66 20 77 | regardl|ess of w|
|00005120| 68 69 63 68 0d 20 20 20 | 20 20 6f 70 65 72 61 6e |hich. | operan|
|00005130| 64 20 69 74 20 77 61 73 | 20 77 72 69 74 74 65 6e |d it was| written|
|00005140| 20 69 6e 2e 20 20 54 68 | 65 20 75 73 75 61 6c 20 | in. Th|e usual |
|00005150| 63 75 73 74 6f 6d 20 77 | 61 73 20 74 6f 20 77 72 |custom w|as to wr|
|00005160| 69 74 65 20 69 74 20 69 | 6e 0d 20 20 20 20 20 6f |ite it i|n. o|
|00005170| 70 65 72 61 6e 64 20 30 | 2e 20 20 4e 6f 77 20 69 |perand 0|. Now i|
|00005180| 74 20 6d 75 73 74 20 62 | 65 20 69 6e 20 6f 70 65 |t must b|e in ope|
|00005190| 72 61 6e 64 20 31 20 69 | 66 20 74 68 65 20 6f 70 |rand 1 i|f the op|
|000051a0| 65 72 61 6e 64 73 20 74 | 6f 20 62 65 0d 20 20 20 |erands t|o be. |
|000051b0| 20 20 65 78 63 68 61 6e | 67 65 64 20 61 72 65 20 | exchan|ged are |
|000051c0| 31 20 61 6e 64 20 32 2e | 0d 0d 60 23 27 0d 20 20 |1 and 2.|..`#'. |
|000051d0| 20 20 20 53 61 79 73 20 | 74 68 61 74 20 61 6c 6c | Says |that all|
|000051e0| 20 66 6f 6c 6c 6f 77 69 | 6e 67 20 63 68 61 72 61 | followi|ng chara|
|000051f0| 63 74 65 72 73 2c 20 75 | 70 20 74 6f 20 74 68 65 |cters, u|p to the|
|00005200| 20 6e 65 78 74 20 63 6f | 6d 6d 61 2c 20 61 72 65 | next co|mma, are|
|00005210| 20 74 6f 0d 20 20 20 20 | 20 62 65 20 69 67 6e 6f | to. | be igno|
|00005220| 72 65 64 20 61 73 20 61 | 20 63 6f 6e 73 74 72 61 |red as a| constra|
|00005230| 69 6e 74 2e 20 20 54 68 | 65 79 20 61 72 65 20 73 |int. Th|ey are s|
|00005240| 69 67 6e 69 66 69 63 61 | 6e 74 20 6f 6e 6c 79 20 |ignifica|nt only |
|00005250| 66 6f 72 0d 20 20 20 20 | 20 63 68 6f 6f 73 69 6e |for. | choosin|
|00005260| 67 20 72 65 67 69 73 74 | 65 72 20 70 72 65 66 65 |g regist|er prefe|
|00005270| 72 65 6e 63 65 73 2e 0d | 0d 60 2a 27 0d 20 20 20 |rences..|.`*'. |
|00005280| 20 20 53 61 79 73 20 74 | 68 61 74 20 74 68 65 20 | Says t|hat the |
|00005290| 66 6f 6c 6c 6f 77 69 6e | 67 20 63 68 61 72 61 63 |followin|g charac|
|000052a0| 74 65 72 20 73 68 6f 75 | 6c 64 20 62 65 20 69 67 |ter shou|ld be ig|
|000052b0| 6e 6f 72 65 64 20 77 68 | 65 6e 0d 20 20 20 20 20 |nored wh|en. |
|000052c0| 63 68 6f 6f 73 69 6e 67 | 20 72 65 67 69 73 74 65 |choosing| registe|
|000052d0| 72 20 70 72 65 66 65 72 | 65 6e 63 65 73 2e 20 20 |r prefer|ences. |
|000052e0| 60 2a 27 20 68 61 73 20 | 6e 6f 20 65 66 66 65 63 |`*' has |no effec|
|000052f0| 74 20 6f 6e 20 74 68 65 | 20 6d 65 61 6e 69 6e 67 |t on the| meaning|
|00005300| 0d 20 20 20 20 20 6f 66 | 20 74 68 65 20 63 6f 6e |. of| the con|
|00005310| 73 74 72 61 69 6e 74 20 | 61 73 20 61 20 63 6f 6e |straint |as a con|
|00005320| 73 74 72 61 69 6e 74 2e | 0d 0d 20 20 20 20 20 48 |straint.|.. H|
|00005330| 65 72 65 20 69 73 20 61 | 6e 20 65 78 61 6d 70 6c |ere is a|n exampl|
|00005340| 65 3a 20 74 68 65 20 36 | 38 30 30 30 20 68 61 73 |e: the 6|8000 has|
|00005350| 20 61 6e 20 69 6e 73 74 | 72 75 63 74 69 6f 6e 20 | an inst|ruction |
|00005360| 74 6f 20 73 69 67 6e 2d | 65 78 74 65 6e 64 0d 20 |to sign-|extend. |
|00005370| 20 20 20 20 61 20 68 61 | 6c 66 77 6f 72 64 20 69 | a ha|lfword i|
|00005380| 6e 20 61 20 64 61 74 61 | 20 72 65 67 69 73 74 65 |n a data| registe|
|00005390| 72 2c 20 61 6e 64 20 63 | 61 6e 20 61 6c 73 6f 20 |r, and c|an also |
|000053a0| 73 69 67 6e 2d 65 78 74 | 65 6e 64 20 61 20 76 61 |sign-ext|end a va|
|000053b0| 6c 75 65 0d 20 20 20 20 | 20 62 79 20 63 6f 70 79 |lue. | by copy|
|000053c0| 69 6e 67 20 69 74 20 69 | 6e 74 6f 20 61 6e 20 61 |ing it i|nto an a|
|000053d0| 64 64 72 65 73 73 20 72 | 65 67 69 73 74 65 72 2e |ddress r|egister.|
|000053e0| 20 20 57 68 69 6c 65 20 | 65 69 74 68 65 72 20 6b | While |either k|
|000053f0| 69 6e 64 20 6f 66 0d 20 | 20 20 20 20 72 65 67 69 |ind of. | regi|
|00005400| 73 74 65 72 20 69 73 20 | 61 63 63 65 70 74 61 62 |ster is |acceptab|
|00005410| 6c 65 2c 20 74 68 65 20 | 63 6f 6e 73 74 72 61 69 |le, the |constrai|
|00005420| 6e 74 73 20 6f 6e 20 61 | 6e 20 61 64 64 72 65 73 |nts on a|n addres|
|00005430| 73 2d 72 65 67 69 73 74 | 65 72 0d 20 20 20 20 20 |s-regist|er. |
|00005440| 64 65 73 74 69 6e 61 74 | 69 6f 6e 20 61 72 65 20 |destinat|ion are |
|00005450| 6c 65 73 73 20 73 74 72 | 69 63 74 2c 20 73 6f 20 |less str|ict, so |
|00005460| 69 74 20 69 73 20 62 65 | 73 74 20 69 66 20 72 65 |it is be|st if re|
|00005470| 67 69 73 74 65 72 0d 20 | 20 20 20 20 61 6c 6c 6f |gister. | allo|
|00005480| 63 61 74 69 6f 6e 20 6d | 61 6b 65 73 20 61 6e 20 |cation m|akes an |
|00005490| 61 64 64 72 65 73 73 20 | 72 65 67 69 73 74 65 72 |address |register|
|000054a0| 20 69 74 73 20 67 6f 61 | 6c 2e 20 20 54 68 65 72 | its goa|l. Ther|
|000054b0| 65 66 6f 72 65 2c 20 60 | 2a 27 0d 20 20 20 20 20 |efore, `|*'. |
|000054c0| 69 73 20 75 73 65 64 20 | 73 6f 20 74 68 61 74 20 |is used |so that |
|000054d0| 74 68 65 20 60 64 27 20 | 63 6f 6e 73 74 72 61 69 |the `d' |constrai|
|000054e0| 6e 74 20 6c 65 74 74 65 | 72 20 28 66 6f 72 20 64 |nt lette|r (for d|
|000054f0| 61 74 61 20 72 65 67 69 | 73 74 65 72 29 20 69 73 |ata regi|ster) is|
|00005500| 0d 20 20 20 20 20 69 67 | 6e 6f 72 65 64 20 77 68 |. ig|nored wh|
|00005510| 65 6e 20 63 6f 6d 70 75 | 74 69 6e 67 20 72 65 67 |en compu|ting reg|
|00005520| 69 73 74 65 72 20 70 72 | 65 66 65 72 65 6e 63 65 |ister pr|eference|
|00005530| 73 2e 0d 0d 20 20 20 20 | 20 20 20 20 20 20 28 64 |s... | (d|
|00005540| 65 66 69 6e 65 5f 69 6e | 73 6e 20 22 65 78 74 65 |efine_in|sn "exte|
|00005550| 6e 64 68 69 73 69 32 22 | 0d 20 20 20 20 20 20 20 |ndhisi2"|. |
|00005560| 20 20 20 20 20 5b 28 73 | 65 74 20 28 6d 61 74 63 | [(s|et (matc|
|00005570| 68 5f 6f 70 65 72 61 6e | 64 3a 53 49 20 30 20 22 |h_operan|d:SI 0 "|
|00005580| 67 65 6e 65 72 61 6c 5f | 6f 70 65 72 61 6e 64 22 |general_|operand"|
|00005590| 20 22 3d 2a 64 2c 61 22 | 29 0d 20 20 20 20 20 20 | "=*d,a"|). |
|000055a0| 20 20 20 20 20 20 20 20 | 20 20 20 20 28 73 69 67 | | (sig|
|000055b0| 6e 5f 65 78 74 65 6e 64 | 3a 53 49 0d 20 20 20 20 |n_extend|:SI. |
|000055c0| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 28 | | (|
|000055d0| 6d 61 74 63 68 5f 6f 70 | 65 72 61 6e 64 3a 48 49 |match_op|erand:HI|
|000055e0| 20 31 20 22 67 65 6e 65 | 72 61 6c 5f 6f 70 65 72 | 1 "gene|ral_oper|
|000055f0| 61 6e 64 22 20 22 30 2c | 67 22 29 29 29 5d 0d 20 |and" "0,|g")))]. |
|00005600| 20 20 20 20 20 20 20 20 | 20 20 20 2e 2e 2e 29 0d | | ...).|
|00005610| 0d 0d 1f 0d 46 69 6c 65 | 3a 20 67 63 63 2e 69 6e |....File|: gcc.in|
|00005620| 66 6f 2c 20 20 4e 6f 64 | 65 3a 20 4e 6f 20 43 6f |fo, Nod|e: No Co|
|00005630| 6e 73 74 72 61 69 6e 74 | 73 2c 20 20 50 72 65 76 |nstraint|s, Prev|
|00005640| 3a 20 4d 6f 64 69 66 69 | 65 72 73 2c 20 20 55 70 |: Modifi|ers, Up|
|00005650| 3a 20 43 6f 6e 73 74 72 | 61 69 6e 74 73 0d 0d 4e |: Constr|aints..N|
|00005660| 6f 74 20 55 73 69 6e 67 | 20 43 6f 6e 73 74 72 61 |ot Using| Constra|
|00005670| 69 6e 74 73 0d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |ints.---|--------|
|00005680| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 0d 0d 53 6f 6d 65 |--------|--..Some|
|00005690| 20 6d 61 63 68 69 6e 65 | 73 20 61 72 65 20 73 6f | machine|s are so|
|000056a0| 20 63 6c 65 61 6e 20 74 | 68 61 74 20 6f 70 65 72 | clean t|hat oper|
|000056b0| 61 6e 64 20 63 6f 6e 73 | 74 72 61 69 6e 74 73 20 |and cons|traints |
|000056c0| 61 72 65 20 6e 6f 74 20 | 72 65 71 75 69 72 65 64 |are not |required|
|000056d0| 2e 0d 46 6f 72 20 65 78 | 61 6d 70 6c 65 2c 20 6f |..For ex|ample, o|
|000056e0| 6e 20 74 68 65 20 56 61 | 78 2c 20 61 6e 20 6f 70 |n the Va|x, an op|
|000056f0| 65 72 61 6e 64 20 76 61 | 6c 69 64 20 69 6e 20 6f |erand va|lid in o|
|00005700| 6e 65 20 63 6f 6e 74 65 | 78 74 20 69 73 20 76 61 |ne conte|xt is va|
|00005710| 6c 69 64 20 69 6e 0d 61 | 6e 79 20 6f 74 68 65 72 |lid in.a|ny other|
|00005720| 20 63 6f 6e 74 65 78 74 | 2e 20 20 4f 6e 20 73 75 | context|. On su|
|00005730| 63 68 20 61 20 6d 61 63 | 68 69 6e 65 2c 20 65 76 |ch a mac|hine, ev|
|00005740| 65 72 79 20 6f 70 65 72 | 61 6e 64 20 63 6f 6e 73 |ery oper|and cons|
|00005750| 74 72 61 69 6e 74 20 77 | 6f 75 6c 64 0d 62 65 20 |traint w|ould.be |
|00005760| 60 67 27 2c 20 65 78 63 | 65 70 74 69 6e 67 20 6f |`g', exc|epting o|
|00005770| 6e 6c 79 20 6f 70 65 72 | 61 6e 64 73 20 6f 66 20 |nly oper|ands of |
|00005780| 60 60 6c 6f 61 64 20 61 | 64 64 72 65 73 73 27 27 |``load a|ddress''|
|00005790| 20 69 6e 73 74 72 75 63 | 74 69 6f 6e 73 0d 77 68 | instruc|tions.wh|
|000057a0| 69 63 68 20 61 72 65 20 | 77 72 69 74 74 65 6e 20 |ich are |written |
|000057b0| 61 73 20 69 66 20 74 68 | 65 79 20 72 65 66 65 72 |as if th|ey refer|
|000057c0| 72 65 64 20 74 6f 20 61 | 20 6d 65 6d 6f 72 79 20 |red to a| memory |
|000057d0| 6c 6f 63 61 74 69 6f 6e | 27 73 20 63 6f 6e 74 65 |location|'s conte|
|000057e0| 6e 74 73 0d 62 75 74 20 | 61 63 74 75 61 6c 20 72 |nts.but |actual r|
|000057f0| 65 66 65 72 20 74 6f 20 | 69 74 73 20 61 64 64 72 |efer to |its addr|
|00005800| 65 73 73 2e 20 20 54 68 | 65 79 20 77 6f 75 6c 64 |ess. Th|ey would|
|00005810| 20 68 61 76 65 20 63 6f | 6e 73 74 72 61 69 6e 74 | have co|nstraint|
|00005820| 20 60 70 27 2e 0d 0d 46 | 6f 72 20 73 75 63 68 20 | `p'...F|or such |
|00005830| 6d 61 63 68 69 6e 65 73 | 2c 20 69 6e 73 74 65 61 |machines|, instea|
|00005840| 64 20 6f 66 20 77 72 69 | 74 69 6e 67 20 60 67 27 |d of wri|ting `g'|
|00005850| 20 61 6e 64 20 60 70 27 | 20 66 6f 72 20 61 6c 6c | and `p'| for all|
|00005860| 20 74 68 65 0d 63 6f 6e | 73 74 72 61 69 6e 74 73 | the.con|straints|
|00005870| 2c 20 79 6f 75 20 63 61 | 6e 20 63 68 6f 6f 73 65 |, you ca|n choose|
|00005880| 20 74 6f 20 77 72 69 74 | 65 20 61 20 64 65 73 63 | to writ|e a desc|
|00005890| 72 69 70 74 69 6f 6e 20 | 77 69 74 68 20 65 6d 70 |ription |with emp|
|000058a0| 74 79 0d 63 6f 6e 73 74 | 72 61 69 6e 74 73 2e 20 |ty.const|raints. |
|000058b0| 20 54 68 65 6e 20 79 6f | 75 20 77 72 69 74 65 20 | Then yo|u write |
|000058c0| 60 22 22 27 20 66 6f 72 | 20 74 68 65 20 63 6f 6e |`""' for| the con|
|000058d0| 73 74 72 61 69 6e 74 20 | 69 6e 20 65 76 65 72 79 |straint |in every|
|000058e0| 0d 60 6d 61 74 63 68 5f | 6f 70 65 72 61 6e 64 27 |.`match_|operand'|
|000058f0| 2e 20 20 41 64 64 72 65 | 73 73 20 6f 70 65 72 61 |. Addre|ss opera|
|00005900| 6e 64 73 20 61 72 65 20 | 69 64 65 6e 74 69 66 69 |nds are |identifi|
|00005910| 65 64 20 62 79 20 77 72 | 69 74 69 6e 67 20 61 6e |ed by wr|iting an|
|00005920| 0d 60 61 64 64 72 65 73 | 73 27 20 65 78 70 72 65 |.`addres|s' expre|
|00005930| 73 73 69 6f 6e 20 61 72 | 6f 75 6e 64 20 74 68 65 |ssion ar|ound the|
|00005940| 20 60 6d 61 74 63 68 5f | 6f 70 65 72 61 6e 64 27 | `match_|operand'|
|00005950| 2c 20 6e 6f 74 20 62 79 | 20 74 68 65 69 72 0d 63 |, not by| their.c|
|00005960| 6f 6e 73 74 72 61 69 6e | 74 73 2e 0d 0d 57 68 65 |onstrain|ts...Whe|
|00005970| 6e 20 74 68 65 20 6d 61 | 63 68 69 6e 65 20 64 65 |n the ma|chine de|
|00005980| 73 63 72 69 70 74 69 6f | 6e 20 68 61 73 20 6a 75 |scriptio|n has ju|
|00005990| 73 74 20 65 6d 70 74 79 | 20 63 6f 6e 73 74 72 61 |st empty| constra|
|000059a0| 69 6e 74 73 2c 20 63 65 | 72 74 61 69 6e 0d 70 61 |ints, ce|rtain.pa|
|000059b0| 72 74 73 20 6f 66 20 63 | 6f 6d 70 69 6c 61 74 69 |rts of c|ompilati|
|000059c0| 6f 6e 20 61 72 65 20 73 | 6b 69 70 70 65 64 2c 20 |on are s|kipped, |
|000059d0| 6d 61 6b 69 6e 67 20 74 | 68 65 20 63 6f 6d 70 69 |making t|he compi|
|000059e0| 6c 65 72 20 66 61 73 74 | 65 72 2e 20 0d 48 6f 77 |ler fast|er. .How|
|000059f0| 65 76 65 72 2c 20 66 65 | 77 20 6d 61 63 68 69 6e |ever, fe|w machin|
|00005a00| 65 73 20 61 63 74 75 61 | 6c 6c 79 20 64 6f 20 6e |es actua|lly do n|
|00005a10| 6f 74 20 6e 65 65 64 20 | 63 6f 6e 73 74 72 61 69 |ot need |constrai|
|00005a20| 6e 74 73 3b 20 61 6c 6c | 20 6d 61 63 68 69 6e 65 |nts; all| machine|
|00005a30| 0d 64 65 73 63 72 69 70 | 74 69 6f 6e 73 20 6e 6f |.descrip|tions no|
|00005a40| 77 20 69 6e 20 65 78 69 | 73 74 65 6e 63 65 20 75 |w in exi|stence u|
|00005a50| 73 65 20 63 6f 6e 73 74 | 72 61 69 6e 74 73 2e 0d |se const|raints..|
|00005a60| 0d 0d 1f 0d 46 69 6c 65 | 3a 20 67 63 63 2e 69 6e |....File|: gcc.in|
|00005a70| 66 6f 2c 20 20 4e 6f 64 | 65 3a 20 53 74 61 6e 64 |fo, Nod|e: Stand|
|00005a80| 61 72 64 20 4e 61 6d 65 | 73 2c 20 20 4e 65 78 74 |ard Name|s, Next|
|00005a90| 3a 20 50 61 74 74 65 72 | 6e 20 4f 72 64 65 72 69 |: Patter|n Orderi|
|00005aa0| 6e 67 2c 20 20 50 72 65 | 76 3a 20 43 6f 6e 73 74 |ng, Pre|v: Const|
|00005ab0| 72 61 69 6e 74 73 2c 20 | 20 55 70 3a 20 4d 61 63 |raints, | Up: Mac|
|00005ac0| 68 69 6e 65 20 44 65 73 | 63 0d 0d 53 74 61 6e 64 |hine Des|c..Stand|
|00005ad0| 61 72 64 20 4e 61 6d 65 | 73 20 66 6f 72 20 50 61 |ard Name|s for Pa|
|00005ae0| 74 74 65 72 6e 73 20 55 | 73 65 64 20 69 6e 20 47 |tterns U|sed in G|
|00005af0| 65 6e 65 72 61 74 69 6f | 6e 0d 3d 3d 3d 3d 3d 3d |eneratio|n.======|
|00005b00| 3d 3d 3d 3d 3d 3d 3d 3d | 3d 3d 3d 3d 3d 3d 3d 3d |========|========|
|00005b10| 3d 3d 3d 3d 3d 3d 3d 3d | 3d 3d 3d 3d 3d 3d 3d 3d |========|========|
|00005b20| 3d 3d 3d 3d 3d 3d 3d 3d | 0d 0d 48 65 72 65 20 69 |========|..Here i|
|00005b30| 73 20 61 20 74 61 62 6c | 65 20 6f 66 20 74 68 65 |s a tabl|e of the|
|00005b40| 20 69 6e 73 74 72 75 63 | 74 69 6f 6e 20 6e 61 6d | instruc|tion nam|
|00005b50| 65 73 20 74 68 61 74 20 | 61 72 65 20 6d 65 61 6e |es that |are mean|
|00005b60| 69 6e 67 66 75 6c 20 69 | 6e 20 74 68 65 0d 52 54 |ingful i|n the.RT|
|00005b70| 4c 20 67 65 6e 65 72 61 | 74 69 6f 6e 20 70 61 73 |L genera|tion pas|
|00005b80| 73 20 6f 66 20 74 68 65 | 20 63 6f 6d 70 69 6c 65 |s of the| compile|
|00005b90| 72 2e 20 20 47 69 76 69 | 6e 67 20 6f 6e 65 20 6f |r. Givi|ng one o|
|00005ba0| 66 20 74 68 65 73 65 20 | 6e 61 6d 65 73 20 74 6f |f these |names to|
|00005bb0| 20 61 6e 0d 69 6e 73 74 | 72 75 63 74 69 6f 6e 20 | an.inst|ruction |
|00005bc0| 70 61 74 74 65 72 6e 20 | 74 65 6c 6c 73 20 74 68 |pattern |tells th|
|00005bd0| 65 20 52 54 4c 20 67 65 | 6e 65 72 61 74 69 6f 6e |e RTL ge|neration|
|00005be0| 20 70 61 73 73 20 74 68 | 61 74 20 69 74 20 63 61 | pass th|at it ca|
|00005bf0| 6e 20 75 73 65 20 74 68 | 65 0d 70 61 74 74 65 72 |n use th|e.patter|
|00005c00| 6e 20 69 6e 20 74 6f 20 | 61 63 63 6f 6d 70 6c 69 |n in to |accompli|
|00005c10| 73 68 20 61 20 63 65 72 | 74 61 69 6e 20 74 61 73 |sh a cer|tain tas|
|00005c20| 6b 2e 0d 0d 60 6d 6f 76 | 4d 27 0d 20 20 20 20 20 |k...`mov|M'. |
|00005c30| 48 65 72 65 20 4d 20 73 | 74 61 6e 64 73 20 66 6f |Here M s|tands fo|
|00005c40| 72 20 61 20 74 77 6f 2d | 6c 65 74 74 65 72 20 6d |r a two-|letter m|
|00005c50| 61 63 68 69 6e 65 20 6d | 6f 64 65 20 6e 61 6d 65 |achine m|ode name|
|00005c60| 2c 20 69 6e 20 6c 6f 77 | 65 72 20 63 61 73 65 2e |, in low|er case.|
|00005c70| 0d 20 20 20 20 20 54 68 | 69 73 20 69 6e 73 74 72 |. Th|is instr|
|00005c80| 75 63 74 69 6f 6e 20 70 | 61 74 74 65 72 6e 20 6d |uction p|attern m|
|00005c90| 6f 76 65 73 20 64 61 74 | 61 20 77 69 74 68 20 74 |oves dat|a with t|
|00005ca0| 68 61 74 20 6d 61 63 68 | 69 6e 65 20 6d 6f 64 65 |hat mach|ine mode|
|00005cb0| 20 66 72 6f 6d 0d 20 20 | 20 20 20 6f 70 65 72 61 | from. | opera|
|00005cc0| 6e 64 20 31 20 74 6f 20 | 6f 70 65 72 61 6e 64 20 |nd 1 to |operand |
|00005cd0| 30 2e 20 20 46 6f 72 20 | 65 78 61 6d 70 6c 65 2c |0. For |example,|
|00005ce0| 20 60 6d 6f 76 73 69 27 | 20 6d 6f 76 65 73 20 66 | `movsi'| moves f|
|00005cf0| 75 6c 6c 2d 77 6f 72 64 | 0d 20 20 20 20 20 64 61 |ull-word|. da|
|00005d00| 74 61 2e 0d 0d 20 20 20 | 20 20 49 66 20 6f 70 65 |ta... | If ope|
|00005d10| 72 61 6e 64 20 30 20 69 | 73 20 61 20 60 73 75 62 |rand 0 i|s a `sub|
|00005d20| 72 65 67 27 20 77 69 74 | 68 20 6d 6f 64 65 20 4d |reg' wit|h mode M|
|00005d30| 20 6f 66 20 61 20 72 65 | 67 69 73 74 65 72 20 77 | of a re|gister w|
|00005d40| 68 6f 73 65 20 6f 77 6e | 0d 20 20 20 20 20 6d 6f |hose own|. mo|
|00005d50| 64 65 20 69 73 20 77 69 | 64 65 72 20 74 68 61 6e |de is wi|der than|
|00005d60| 20 4d 2c 20 74 68 65 20 | 65 66 66 65 63 74 20 6f | M, the |effect o|
|00005d70| 66 20 74 68 69 73 20 69 | 6e 73 74 72 75 63 74 69 |f this i|nstructi|
|00005d80| 6f 6e 20 69 73 20 74 6f | 20 73 74 6f 72 65 0d 20 |on is to| store. |
|00005d90| 20 20 20 20 74 68 65 20 | 73 70 65 63 69 66 69 65 | the |specifie|
|00005da0| 64 20 76 61 6c 75 65 20 | 69 6e 20 74 68 65 20 70 |d value |in the p|
|00005db0| 61 72 74 20 6f 66 20 74 | 68 65 20 72 65 67 69 73 |art of t|he regis|
|00005dc0| 74 65 72 20 74 68 61 74 | 20 63 6f 72 72 65 73 70 |ter that| corresp|
|00005dd0| 6f 6e 64 73 0d 20 20 20 | 20 20 74 6f 20 6d 6f 64 |onds. | to mod|
|00005de0| 65 20 4d 2e 20 20 54 68 | 65 20 65 66 66 65 63 74 |e M. Th|e effect|
|00005df0| 20 6f 6e 20 74 68 65 20 | 72 65 73 74 20 6f 66 20 | on the |rest of |
|00005e00| 74 68 65 20 72 65 67 69 | 73 74 65 72 20 69 73 20 |the regi|ster is |
|00005e10| 75 6e 64 65 66 69 6e 65 | 64 2e 0d 0d 20 20 20 20 |undefine|d... |
|00005e20| 20 54 68 69 73 20 63 6c | 61 73 73 20 6f 66 20 70 | This cl|ass of p|
|00005e30| 61 74 74 65 72 6e 73 20 | 69 73 20 73 70 65 63 69 |atterns |is speci|
|00005e40| 61 6c 20 69 6e 20 73 65 | 76 65 72 61 6c 20 77 61 |al in se|veral wa|
|00005e50| 79 73 2e 20 20 46 69 72 | 73 74 20 6f 66 0d 20 20 |ys. Fir|st of. |
|00005e60| 20 20 20 61 6c 6c 2c 20 | 65 61 63 68 20 6f 66 20 | all, |each of |
|00005e70| 74 68 65 73 65 20 6e 61 | 6d 65 73 20 2a 6d 75 73 |these na|mes *mus|
|00005e80| 74 2a 20 62 65 20 64 65 | 66 69 6e 65 64 2c 20 62 |t* be de|fined, b|
|00005e90| 65 63 61 75 73 65 20 74 | 68 65 72 65 20 69 73 20 |ecause t|here is |
|00005ea0| 6e 6f 0d 20 20 20 20 20 | 6f 74 68 65 72 20 77 61 |no. |other wa|
|00005eb0| 79 20 74 6f 20 63 6f 70 | 79 20 61 20 64 61 74 75 |y to cop|y a datu|
|00005ec0| 6d 20 66 72 6f 6d 20 6f | 6e 65 20 70 6c 61 63 65 |m from o|ne place|
|00005ed0| 20 74 6f 20 61 6e 6f 74 | 68 65 72 2e 0d 0d 20 20 | to anot|her... |
|00005ee0| 20 20 20 53 65 63 6f 6e | 64 2c 20 74 68 65 73 65 | Secon|d, these|
|00005ef0| 20 70 61 74 74 65 72 6e | 73 20 61 72 65 20 6e 6f | pattern|s are no|
|00005f00| 74 20 75 73 65 64 20 73 | 6f 6c 65 6c 79 20 69 6e |t used s|olely in|
|00005f10| 20 74 68 65 20 52 54 4c | 20 67 65 6e 65 72 61 74 | the RTL| generat|
|00005f20| 69 6f 6e 0d 20 20 20 20 | 20 70 61 73 73 2e 20 20 |ion. | pass. |
|00005f30| 45 76 65 6e 20 74 68 65 | 20 72 65 6c 6f 61 64 20 |Even the| reload |
|00005f40| 70 61 73 73 20 63 61 6e | 20 67 65 6e 65 72 61 74 |pass can| generat|
|00005f50| 65 20 6d 6f 76 65 20 69 | 6e 73 6e 73 20 74 6f 20 |e move i|nsns to |
|00005f60| 63 6f 70 79 0d 20 20 20 | 20 20 76 61 6c 75 65 73 |copy. | values|
|00005f70| 20 66 72 6f 6d 20 73 74 | 61 63 6b 20 73 6c 6f 74 | from st|ack slot|
|00005f80| 73 20 69 6e 74 6f 20 74 | 65 6d 70 6f 72 61 72 79 |s into t|emporary|
|00005f90| 20 72 65 67 69 73 74 65 | 72 73 2e 20 20 57 68 65 | registe|rs. Whe|
|00005fa0| 6e 20 69 74 20 64 6f 65 | 73 0d 20 20 20 20 20 73 |n it doe|s. s|
|00005fb0| 6f 2c 20 6f 6e 65 20 6f | 66 20 74 68 65 20 6f 70 |o, one o|f the op|
|00005fc0| 65 72 61 6e 64 73 20 69 | 73 20 61 20 68 61 72 64 |erands i|s a hard|
|00005fd0| 20 72 65 67 69 73 74 65 | 72 20 61 6e 64 20 74 68 | registe|r and th|
|00005fe0| 65 20 6f 74 68 65 72 20 | 69 73 20 61 6e 0d 20 20 |e other |is an. |
|00005ff0| 20 20 20 6f 70 65 72 61 | 6e 64 20 74 68 61 74 20 | opera|nd that |
|00006000| 63 61 6e 20 6e 65 65 64 | 20 74 6f 20 62 65 20 72 |can need| to be r|
|00006010| 65 6c 6f 61 64 65 64 20 | 69 6e 74 6f 20 61 20 72 |eloaded |into a r|
|00006020| 65 67 69 73 74 65 72 2e | 0d 0d 20 20 20 20 20 54 |egister.|.. T|
|00006030| 68 65 72 65 66 6f 72 65 | 2c 20 77 68 65 6e 20 67 |herefore|, when g|
|00006040| 69 76 65 6e 20 73 75 63 | 68 20 61 20 70 61 69 72 |iven suc|h a pair|
|00006050| 20 6f 66 20 6f 70 65 72 | 61 6e 64 73 2c 20 74 68 | of oper|ands, th|
|00006060| 65 20 70 61 74 74 65 72 | 6e 20 6d 75 73 74 0d 20 |e patter|n must. |
|00006070| 20 20 20 20 67 65 6e 65 | 72 61 74 65 20 52 54 4c | gene|rate RTL|
|00006080| 20 77 68 69 63 68 20 6e | 65 65 64 73 20 6e 6f 20 | which n|eeds no |
|00006090| 72 65 6c 6f 61 64 69 6e | 67 20 61 6e 64 20 6e 65 |reloadin|g and ne|
|000060a0| 65 64 73 20 6e 6f 20 74 | 65 6d 70 6f 72 61 72 79 |eds no t|emporary|
|000060b0| 0d 20 20 20 20 20 72 65 | 67 69 73 74 65 72 73 2d |. re|gisters-|
|000060c0| 2d 6e 6f 20 72 65 67 69 | 73 74 65 72 73 20 6f 74 |-no regi|sters ot|
|000060d0| 68 65 72 20 74 68 61 6e | 20 74 68 65 20 6f 70 65 |her than| the ope|
|000060e0| 72 61 6e 64 73 2e 20 20 | 46 6f 72 20 65 78 61 6d |rands. |For exam|
|000060f0| 70 6c 65 2c 0d 20 20 20 | 20 20 69 66 20 79 6f 75 |ple,. | if you|
|00006100| 20 73 75 70 70 6f 72 74 | 20 74 68 65 20 70 61 74 | support| the pat|
|00006110| 74 65 72 6e 20 77 69 74 | 68 20 61 20 60 64 65 66 |tern wit|h a `def|
|00006120| 69 6e 65 5f 65 78 70 61 | 6e 64 27 2c 20 74 68 65 |ine_expa|nd', the|
|00006130| 6e 20 69 6e 20 73 75 63 | 68 0d 20 20 20 20 20 61 |n in suc|h. a|
|00006140| 20 63 61 73 65 20 74 68 | 65 20 60 64 65 66 69 6e | case th|e `defin|
|00006150| 65 5f 65 78 70 61 6e 64 | 27 20 6d 75 73 74 6e 27 |e_expand|' mustn'|
|00006160| 74 20 63 61 6c 6c 20 60 | 66 6f 72 63 65 5f 72 65 |t call `|force_re|
|00006170| 67 27 20 6f 72 20 61 6e | 79 20 6f 74 68 65 72 0d |g' or an|y other.|
|00006180| 20 20 20 20 20 73 75 63 | 68 20 66 75 6e 63 74 69 | suc|h functi|
|00006190| 6f 6e 20 77 68 69 63 68 | 20 6d 69 67 68 74 20 67 |on which| might g|
|000061a0| 65 6e 65 72 61 74 65 20 | 6e 65 77 20 70 73 65 75 |enerate |new pseu|
|000061b0| 64 6f 20 72 65 67 69 73 | 74 65 72 73 2e 0d 0d 20 |do regis|ters... |
|000061c0| 20 20 20 20 54 68 69 73 | 20 72 65 71 75 69 72 65 | This| require|
|000061d0| 6d 65 6e 74 20 65 78 69 | 73 74 73 20 65 76 65 6e |ment exi|sts even|
|000061e0| 20 66 6f 72 20 73 75 62 | 77 6f 72 64 20 6d 6f 64 | for sub|word mod|
|000061f0| 65 73 20 6f 6e 20 61 20 | 52 49 53 43 20 6d 61 63 |es on a |RISC mac|
|00006200| 68 69 6e 65 0d 20 20 20 | 20 20 77 68 65 72 65 20 |hine. | where |
|00006210| 66 65 74 63 68 69 6e 67 | 20 74 68 6f 73 65 20 6d |fetching| those m|
|00006220| 6f 64 65 73 20 66 72 6f | 6d 20 6d 65 6d 6f 72 79 |odes fro|m memory|
|00006230| 20 6e 6f 72 6d 61 6c 6c | 79 20 72 65 71 75 69 72 | normall|y requir|
|00006240| 65 73 20 73 65 76 65 72 | 61 6c 0d 20 20 20 20 20 |es sever|al. |
|00006250| 69 6e 73 6e 73 20 61 6e | 64 20 73 6f 6d 65 20 74 |insns an|d some t|
|00006260| 65 6d 70 6f 72 61 72 79 | 20 72 65 67 69 73 74 65 |emporary| registe|
|00006270| 72 73 2e 20 20 4c 6f 6f | 6b 20 69 6e 20 60 73 70 |rs. Loo|k in `sp|
|00006280| 75 72 2e 6d 64 27 20 74 | 6f 20 73 65 65 0d 20 20 |ur.md' t|o see. |
|00006290| 20 20 20 68 6f 77 20 74 | 68 65 20 72 65 71 75 69 | how t|he requi|
|000062a0| 72 65 6d 65 6e 74 20 63 | 61 6e 20 62 65 20 73 61 |rement c|an be sa|
|000062b0| 74 69 73 66 69 65 64 2e | 0d 0d 20 20 20 20 20 54 |tisfied.|.. T|
|000062c0| 68 65 20 76 61 72 69 65 | 74 79 20 6f 66 20 6f 70 |he varie|ty of op|
|000062d0| 65 72 61 6e 64 73 20 74 | 68 61 74 20 68 61 76 65 |erands t|hat have|
|000062e0| 20 72 65 6c 6f 61 64 73 | 20 64 65 70 65 6e 64 73 | reloads| depends|
|000062f0| 20 6f 6e 20 74 68 65 20 | 72 65 73 74 20 6f 66 0d | on the |rest of.|
|00006300| 20 20 20 20 20 74 68 65 | 20 6d 61 63 68 69 6e 65 | the| machine|
|00006310| 20 64 65 73 63 72 69 70 | 74 69 6f 6e 2c 20 62 75 | descrip|tion, bu|
|00006320| 74 20 74 79 70 69 63 61 | 6c 6c 79 20 6f 6e 20 61 |t typica|lly on a|
|00006330| 20 52 49 53 43 20 6d 61 | 63 68 69 6e 65 20 74 68 | RISC ma|chine th|
|00006340| 65 73 65 0d 20 20 20 20 | 20 63 61 6e 20 6f 6e 6c |ese. | can onl|
|00006350| 79 20 62 65 20 70 73 65 | 75 64 6f 20 72 65 67 69 |y be pse|udo regi|
|00006360| 73 74 65 72 73 20 74 68 | 61 74 20 64 69 64 20 6e |sters th|at did n|
|00006370| 6f 74 20 67 65 74 20 68 | 61 72 64 20 72 65 67 69 |ot get h|ard regi|
|00006380| 73 74 65 72 73 2c 0d 20 | 20 20 20 20 77 68 69 6c |sters,. | whil|
|00006390| 65 20 6f 6e 20 6f 74 68 | 65 72 20 6d 61 63 68 69 |e on oth|er machi|
|000063a0| 6e 65 73 20 65 78 70 6c | 69 63 69 74 20 6d 65 6d |nes expl|icit mem|
|000063b0| 6f 72 79 20 72 65 66 65 | 72 65 6e 63 65 73 20 77 |ory refe|rences w|
|000063c0| 69 6c 6c 20 67 65 74 0d | 20 20 20 20 20 6f 70 74 |ill get.| opt|
|000063d0| 69 6f 6e 61 6c 20 72 65 | 6c 6f 61 64 73 2e 0d 0d |ional re|loads...|
|000063e0| 20 20 20 20 20 54 68 65 | 20 63 6f 6e 73 74 72 61 | The| constra|
|000063f0| 69 6e 74 73 20 6f 6e 20 | 61 20 60 6d 6f 76 65 4d |ints on |a `moveM|
+--------+-------------------------+-------------------------+--------+--------+
Only 25.0 KB of data is shown above.